[Forums] [Shop] [Resources] [Training] [About] [Solutions] [Consulting] [News] [Links]

Questions s I hope you enjoy this FREE online training. Let me know if you'd like to see more! You can email me at jmo@filemakerpros.com. And, if you really like this online training, consider one of my live classes based on my wildly popular book and CD ROM. Happy FileMaking!

Idiot Proofing

Polishing up the Solution

There is one more addition that really makes this solution user-friendly. When the user performs a search and locates multiple records, that aren't really aware of the fact unless they are familiar with FileMaker. Your best solution is to show the user a columnar report layout when multiple records are found and a standard layout when a single record is found. This can be done with a simple IF statement that checks for the current found count.

Advanced Exercise

As you have probably noticed, the final script repeats the Toggle Status Area and Toggle Window scripts steps over and over. How can you use Modular Scripting to shorten the script? Modular Scripting is a method of programming FileMaker the reuses code whenever possible.

The answer is to break-out the Toggle Status Area and Toggle Window script steps into a separate script. Each time the Find script needs to toggle the window size, just call on the script. This makes the main find script a lot easier to read since there are less script steps. And, if you need to add something onto the Toggle Window script, you just need to modify it once rather than locating everywhere in your other scripts where they might toggle the window.

Toggle Window script n FIND.fp5

Notice that the Toggle Status Area script uses the Toggle option rather than Show or Hide. This enables you to use one script to show and hide the status area, rather than one modular script for showing and another for hiding.

Download an example FileMaker file  Mac  Win .

Previous | DONE


Exclamation s Database Pros offers training classes across the globe. Classes include the wildly popular Intermediate and Advanced Scriptology training series.


Database Pros