From Xojo Documentation
|You are currently browsing the old Xojo documentation site. Please visit the new Xojo documentation site!|
|result||Integer||The byte position of the first occurrence of find in source.
If the search string cannot be located in source, this returns -1.
|start||Integer||Optional byte position from which to begin searching the source string. One is the default if omitted.|
|find||String||Required. String expression being sought.|
|stringVariable||String||Any variable of type String.|
If the find string is not found within the source string, -1 (zero) is returned. IndexOfBytes is essentially case-sensitive since it treats the string as a series of raw bytes. It should be used instead of String.IndexOf when the string represents binary data.
If you need to find the character position of the find string within the source string, use the String.IndexOf function.
This example uses the IndexOfBytes function to locate a String within another string.