AFSearchTokenCollection.IndexOf Method
- Last UpdatedNov 18, 2025
- 2 minute read
- PI System
- AF SDK 2024 R2
- Developer
Searches for the specified object and returns the zero-based index of the first occurrence within the entire ListT.
Namespace: OSIsoft.AF.Search
Assembly: OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182
Syntax
public int IndexOf( AFSearchTokenBase item )
Public Function IndexOf ( item As AFSearchTokenBase ) As Integer Dim instance As AFSearchTokenCollection Dim item As AFSearchTokenBase Dim returnValue As Integer returnValue = instance.IndexOf(item)
public: virtual int IndexOf( AFSearchTokenBase^ item ) sealed
abstract IndexOf : item : AFSearchTokenBase -> int override IndexOf : item : AFSearchTokenBase -> int
Parameters
- item
- Type: OSIsoft.AF.SearchAFSearchTokenBase
The object to locate in the ListT. The value can be null for reference types.
Return Value
Type: Int32The zero-based index of the first occurrence of item within the entire ListT, if found; otherwise, –1.