System.Collections.Generic.Dictionary<TKey,TValue>.Keys Property
Gets a collection that contains the keys in the dictionary.


public Dictionary<TKey, TValue>.KeyCollection Keys { get; }


A collection of the keys in the dictionary.


This property is read-only.

The order of the keys in the key collection is unspecified, but it is the same order as the associated values in the value collection returned by the Dictionary<TKey, TValue>.Values property.

If the dictionary is modified, or the value of any key in the dictionary is modified, the behavior of the key collection is unspecified.


Namespace: System.Collections.Generic
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions:,
Since: .NET 2.0