ListBox::IntegerCollection::IndexOf Method (Int32)
.NET Framework (current version)
Retrieves the index within the ListBox::IntegerCollection of the specified integer.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
Parameters
- item
-
Type:
System::Int32
The integer for which to retrieve the index.
Return Value
Type: System::Int32The zero-based index of the integer in the ListBox::IntegerCollection; otherwise, negative one (-1).
Use the IndexOf method to determine where an item is located within the collection. To determine whether an item is located within the collection before calling this method, use the Contains method.
.NET Framework
Available since 2.0
Available since 2.0
Show: