find() Function

Returns index location of case-sensitive substring with given string. Returns the one-based location index of the first character of the first match.

Syntax

find( search_text, within_text, [start_num] )

search_text: (Text) The text that will be searched for.

within_text: (Text) The text that will be searched in.

start_num: (Number) The index of the first character within the within_text value from which to start searching. 0 by default.

Returns

Number

Examples

You can experiment with this function in the test box below.

Test Input

find("to","boston",1) returns 4

See Also

search(): Use this function to perform a case-insensitive search.

FEEDBACK