Please enable JavaScript to view this site.

Returns the zero-based index of the first occurrence of the specified sub string within the text. The search is done case-sensitive. Returns -1 if the sought string isn't found.

 

int IndexOf(string text; string subString)

 

text

The string to search inside.

subString

The sub string to search for.

Example

IndexOf("Lorem ipsum";"ipsum")

Returns 6.

  

Keyboard Navigation

F7 for caret browsing
Hold ALT and press letter

This Info: ALT+q
Page Header: ALT+h
Topic Header: ALT+t
Topic Body: ALT+b
Contents: ALT+c
Search: ALT+s
Exit Menu/Up: ESC