BE_TextExtractWords

BE_TextExtractWords ( text { ; wordPrefix } )

Originally an internal function, we've made this one visible in case it's useful to others.  This returns a list of all the "words" in the text that start with either $ or @.  We use this in BaseElements to retrieve all the variables from a calculation.

Version 4.2 : Made visible in the functions list.

Parameters :
text : the text to search on.
wordPrefix : if left out, the default is both $ and @.  Otherwise you can specifiy a single option, either $ or @.

Result : a list of all the words in the text starting with one of the two allowed characters.

Notes : words are delimited ( ended ) by one of the following characters :

" ;+-=*/&^<>\t\r[]()\u2260\u2264\u2265,"

Note that this list of characters includes a space.  The ones starting with \u are single unicode characters.

Also note that this function leaves out code within FileMaker comments, so from // to the endOfLine and from /* to */.  It won't find any examples inside those characters.

Still need help? Contact Us Contact Us