Bridge

String..::..IndexOf Method (String, Int32)

Reports the zero-based index of the first occurrence of the specified string in this instance. The search starts at a specified character position.

Namespace:  System
Assembly:  Bridge (in Bridge.dll)

Syntax


[TemplateAttribute]
public int IndexOf(
	string searchValue,
	int fromIndex
)
<TemplateAttribute> _
Public Function IndexOf ( _
	searchValue As String, _
	fromIndex As Integer _
) As Integer
[TemplateAttribute]
public:
int^ IndexOf(
	String^ searchValue, 
	int^ fromIndex
)

Parameters

searchValue
Type: System..::..String
fromIndex
Type: System..::..Int32

Return Value

The zero-based index position of value if that string is found, or -1 if it is not. If value is Empty, the return value is startIndex.

Exceptions


ExceptionCondition
System..::..ArgumentNullExceptionvalue is null.
System..::..ArgumentOutOfRangeExceptionstartIndex is less than 0 (zero) or greater than the length of this string.