Lingo Dictionary > A-C > contains |
![]() ![]() ![]() |
contains
Syntax
stringExpression1
contains
stringExpression2
Description
Operator; compares two strings and determines whether stringExpression1
contains stringExpression2
(TRUE
) or not (FALSE
).
The contains
comparison operator has a precedence level of 1.
The contains
comparison operator is useful for checking whether the user types a specific character or string of characters. You can also use the contains
operator to search one or more fields for specific strings of characters.
Note: The string comparison is not case sensitive, but it is sensitive to diacritical marks; "a" and "A" are treated the same, but "A" and "Ä" are not.
Example
This example determines whether a character passed to it is a digit:
on isNumber aLetter digits = "1234567890" if digits contains aLetter then return TRUE else return FALSE end if end
See also
offset() (string function)
, starts
![]() ![]() ![]() |