O'Reilly logo

FileMaker Pro 14: The Missing Manual by Susan Prosser, Stuart Gripman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 18. Advanced Scripting

In Chapters Chapter 12 and Chapter 13, you learned about the Script Workspace and some of the most useful script steps. Some scripts, like creating reports or navigation, are simple to create, and to maintain if your needs change. But other scripts handle processes that would be difficult, or even impossible, for mere mortals to do without scripted aid. To give you the confidence to tackle tougher scripting chores, this chapter will build on what you already know, and also introduce you to some more powerful scripting tools. By the end of this chapter, you’ll know how to:

  • Add comments to your work

  • Add user feedback to your scripts

  • Create parameters to make a single script behave different ways

  • Store temporary values using script variables

  • Plan for and handle errors

  • Use advanced script triggers

  • Create modular scripts

Note

Download this chapter’s sample file from this book’s Missing CD page at www.missingmanuals.com/cds/fmp14mm. Use CH18 Invoices_Start.fmp12 to work in and use CH18 Invoices_End.fmp12 to see the completed examples.

Commenting Scripts

When you look at a script someone else created—or one you created a long time ago—you can’t always tell what the script does just by reading the steps. To help keep things clear, add comments to your script. You add each comment by using a Comment script step. This step has just one option: the text of the comment itself. The Comment step is special for two reasons. First, it doesn’t do anything. Second, it appears ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required