Idiot Proofing
No Criteria Entered
What if the user doesn't enter any find criteria and clicks the Find button. That user will get the following error message from FileMaker.

Standard FileMaker error messaqge when find criteria are entered
However, you are trapping for errors, so this error will never appear. Instead, FileMaker will simply continue the script as if nothing had ever happened. Actually, FileMaker will find all the records in the database. This may confuse the user, thinking their find criteria matched every record in the database. That's why capturing errors is such a huge responsibility. Here is the new script to trap for no find criteria. The new and modified script steps have arrows at the left of each command.

Find w/ option for No Find Criteria script n FIND.fp5
Notice that a Set Field script command has been added. In order to trap for multiple errors, it is necessary to place the error into a global field. FileMaker only stores the error in memory temporarily. Besides this change, the others are fairly easy to understand. All that is done is to check for the error number which corresponds to no records found.
Previous | Next
|