Determines if the specified item is located within the collection.
[Visual Basic] Public Overridable Function Contains( _ ByVal value As Object _ ) As Boolean Implements IList.Contains [C#] public virtual bool Contains( object value ); [C++] public: virtual bool Contains( Object* value ); [JScript] public function Contains( value : Object ) : Boolean;
- An object representing the item to locate in the collection.
true if the item is located within the collection; otherwise, false.
The Contains method enables you to determine if an object is a member of the collection. Once you know that the item is located within the collection, you can use the IndexOf method to determine where the item is located within the collection.
Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, .NET Compact Framework