Xbasic
WORD_EXISTS Function
Syntax
result as L = word_exists(C string ,C word [,C delimiter ])
Arguments
- stringCharacter
A CR-LF delimited list of words or entries.
- wordCharacter
The word or entry to find in List.
- delimiterCharacter
Default = crlf(). Defines the character delimiter between words.
Returns
- resultLogical
Returns .T. if the word is found in list. Otherwise, returns .F.
Description
Does a search for a word in a list of words, ignoring case.
Discussion
The WORD_EXISTS() function determines whether a word exists in a list.
Example
dim s as C s = <<%a% Monday Tuesday Wednesday Thursday Friday Saturday Sunday %a% ? word_exists(s, "Friday", crlf()) = .T. ? word_exists(s, "monday", crlf()) = .T.
See Also