InstanceDataCollectionCollection.Keys Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Gets the object and counter registry keys for the objects associated with this instance data collection.

Namespace:   System.Diagnostics
Assembly:  System (in System.dll)

member Keys : ICollection with get

Property Value

Type: System.Collections.ICollection

An ICollection that represents a set of object-specific registry keys.

Each software component creates keys for its objects and counters when it is installed and writes counter data while it is executing. You can access this data as you would access any other registry data. However, although you use the registry to collect performance data, the data is not stored in the registry database. Instead, the system collects the data from the appropriate system object managers.

The following code example uses the Keys property of an InstanceDataCollectionCollection to return a collection of counter names, which it converts to an array of String. It generates an array of InstanceDataCollection objects using the Values property. For each element in the array of counter names, it displays the name and calls a function to process the associated InstanceDataCollection.

No code example is currently available or this language may not be supported.

.NET Framework
Available since 1.1
Return to top
Show: