Dennis @ PerfectForms
The documentation on the Search Function is incorrect. I apologize for the misguidance. The search function will simply return a true or false. I ran a test using your scenario. I used a hidden field into which I returned the value (true or false). Then I created a simple branch behavior that says if the value in the hidden field is true, then show a message and delete the value in the text input field. If it is not, then do nothing. *I used the flag “i” in the function to ignore the case of the letters.* Do not use the “g” flag.
I would use search rather than Index of because you only need to find one occurrence of “PO Box” to cause a problem.