strBeginsWith()
Purpose
Used to determine whether a string begins with a specific character or series of characters.
Description
Receives two strings of any length, then returns either true or false to indicate whether the supplied string begins with the other.
Syntax
result = strBeginsWith( stringVar, to_find )
Arguments
result True (1) or false (0) result to indicate whether the string begins with the search target
stringVar The string being checked
to_find The string being searched for
Example
stringVar = "FUZE"
to_find = "F"
loop
clear()
if strBeginsWith( stringVar, to_find )
print( "String '", stringVar, "' begins with '", to_find, "'" )
else
print( "String '", stringVar, "' does not begin with '", to_find, "'" )
endif
update()
repeat
Associated Commands
str(), strContains(), strEndsWith(), strFind(), strReplace(), stringHash()