This documentation is archived and is not being maintained.

DiscoveryClientReferenceCollection.Values Property

Gets an System.Collections.ICollection object with all the values in the DiscoveryClientReferenceCollection.

[Visual Basic]
Public ReadOnly Property Values As ICollection
[C#]
public ICollection Values {get;}
[C++]
public: __property ICollection* get_Values();
[JScript]
public function get Values() : ICollection;

Property Value

An ICollection containing the values in the DiscoveryClientReferenceCollection.

Example

[Visual Basic] 
' Retrieve the values in the collection.
Dim myCollection1 As ICollection = myDiscoveryClientReferenceCollection.Values
Dim myObjectCollection1(myDiscoveryClientReferenceCollection.Count) As Object
myCollection1.CopyTo(myObjectCollection1, 0)

Console.WriteLine("The objects in the collection are:")
For iIndex = 0 To myObjectCollection1.Length - 1
    Console.WriteLine(myObjectCollection1(iIndex))
Next iIndex

[C#] 
// Retrieve the values in the collection.
ICollection myCollection1 = myDiscoveryClientReferenceCollection.Values;
object[] myObjectCollection1 = 
    new object[myDiscoveryClientReferenceCollection.Count];
myCollection1.CopyTo(myObjectCollection1, 0);

Console.WriteLine("The objects in the collection are:");
for (int iIndex=0; iIndex < myObjectCollection1.Length; iIndex++)
{
   Console.WriteLine(myObjectCollection1[iIndex]);
}

[C++] 
// Retrieve the values in the collection.
ICollection* myCollection1 = myDiscoveryClientReferenceCollection->Values;
Object* myObjectCollection1[] =
   new Object*[myDiscoveryClientReferenceCollection->Count];
myCollection1->CopyTo(myObjectCollection1, 0);

Console::WriteLine(S"The objects in the collection are:");
for (int iIndex=0; iIndex < myObjectCollection1->Length; iIndex++) {
   Console::WriteLine(myObjectCollection1->Item[iIndex]);
}

[JScript] No example is available for JScript. To view a Visual Basic, C#, or C++ example, click the Language Filter button Language Filter in the upper-left corner of the page.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

DiscoveryClientReferenceCollection Class | DiscoveryClientReferenceCollection Members | System.Web.Services.Discovery Namespace

Show: