IndexOf Method
Returns the zero based index of the first occurrence of the specified string within the entire ReadOnlyStringCollection class.
Namespace: Microsoft.CommerceServer.Runtime
Assembly: Microsoft.CommerceServer.CrossTierTypes (in Microsoft.CommerceServer.CrossTierTypes.dll)
Syntax
'Declaration
Public Function IndexOf ( _
item As String _
) As Integer
'Usage
Dim instance As ReadOnlyStringCollection
Dim item As String
Dim returnValue As Integer
returnValue = instance.IndexOf(item)
public int IndexOf(
string item
)
public:
int IndexOf(
String^ item
)
public function IndexOf(
item : String
) : int
Parameters
- item
Type: System..::.String
The string for which to find the index.
Return Value
Type: System..::.Int32
The zero-based index of the first occurrence within the ReadOnlyStringCollection class.
Remarks
Searches for the specified string and returns the zero-based index of the first occurrence within the entire ReadOnlyStringCollection. Returns -1 if the specified string is not found.
Permissions
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
ReadOnlyStringCollection Class