Database Reference
In-Depth Information
Figure 13-5. Each kind of call gets its own icon in the call stack. From top: A plain scroll means
the script was either selected from the Scripts menu or called as a subscript; the script name is to
the right. The scroll with a little starburst means it was invoked by a script trigger; the script name
is to the right. The menu icon is for scripts called from a Custom Menu item; the item's name as it
appears in the menus is to the right. The downward arrow icon indicates an action invoked by
pressing a button, the name of which appears to the right. All stack types show the name of the file
in parentheses. The button type adds the name of the layout where the button resides.
Working with the Debugger Window
The debugger window doesn't work like FileMaker's other dialog boxes. When it's open on
the screen, you can still interact with your database window. Even when a script is running
(but paused waiting for you to step), you can move database windows around, switch lay-
outs, and even type data into records. That way, you can poke around in your database while
the script runs to see how things are progressing. It also lets you totally mess up your script
by putting it in a state it would normally never reach, like an inappropriate layout, or a
mussed-up global field. And although you can edit existing records, you can't create new re-
cords, delete records, or open new windows.
You're free to arrange the debugger and database windows on the screen so you can see as
much as possible while your script runs. You can also resize the debugger window at any
time to make more space.
WARNING
Before you get too hung up trying to fit your layouts on the screen so you can see field values and
the like, read about the Data Viewer in the next section. It's often a better choice if you're trying to
watch the data or variables change.
As long as the Script Debugger window is showing, FileMaker debugs every script that runs.
If you choose Tools→Script Debugger, then the debugger window disappears, and script ex-
ecution goes back to normal. You can also simply close the debugger window to turn it off. If
a script is executing at the time you close the debugger window, it will continue running until
finished.
Search WWH ::




Custom Search