Determines whether a substring is stored within a string.
@Contains( string ; substring )
string
Text or text list. The string(s) you want to search.
substring
Text or text list. The string(s) you want to search for in string.
flag
Boolean.
This function is case-sensitive.
If either parameter is a list, the function returns 1 if any element of parameter 1 contains any element of parameter 2.
You cannot use this function to test for substrings in a rich text field.
Avoid using this function to test for an exact match (that is, parameter 2 equals parameter 1). The result will be wrong if parameter 1 is not an exact match but does contain parameter 2. Use the equal operator or @IsMember, which will give the desired result and are more efficient.
@Contains("Hi There";"Th")
@Contains("Tom":"Dick":"Harry";"Harry":"Tom")
@Contains("Tom";"Tom":"Dick":"Harry")
@If(@Contains(ProductLeadTime;"weeks":"month"); @If(!@IsTime(RequestedShipDate);
@Failure("You must request a valid ship date.");@Success;@Success)
SELECT form = "Memo" & @Contains(@LowerCase(Subject); "mary lamb")
@Command([Compose]; @If(@Contains(@UserRoles; "WebUser"); "WebForm"; "NotesForm"))
InStr function in the LotusScript® language