DiscoveryClientDocumentCollection.Keys Property


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

Gets an System.Collections.ICollection object with all the keys in the DiscoveryClientDocumentCollection.

Namespace:   System.Web.Services.Discovery
Assembly:  System.Web.Services (in System.Web.Services.dll)

public ICollection Keys { get; }

Property Value

Type: System.Collections.ICollection

An ICollection containing the keys of the DiscoveryClientDocumentCollection.

The following code example outputs the keys within the DiscoveryClientDocumentCollection to the console.

ICollection myCollection = myDiscoveryClientDocumentCollection.Keys;
object[] myObjectCollection = 
               new object[myDiscoveryClientDocumentCollection.Count];
myCollection.CopyTo(myObjectCollection, 0);
Console.WriteLine("The discovery documents in the collection are :");
for (int iIndex=0; iIndex < myObjectCollection.Length; iIndex++)

.NET Framework
Available since 1.1
Return to top