FindSubString

The   NWScript command locates one string within another.

Definition
The returned value is the position of the first (leftmost) occurrence of  within   at or after the starting position. This value is zero-based, which means it could also be viewed as the number of characters in  to the left of the first occurrence of. Using the third parameter does not affect how the return value should be interpreted; if the substring is found, then the returned value will be at least  since that is where the search began. If an error is encountered (such as the string not being found), &minus;1 is returned.

The third parameter was added in patch 1.69.