Note: This is a work in progress and will be formatting errors. Read more about the project on the home page. Debug a scriptHyperCard provides some useful tools for troubleshooting your scripts. These debugging tools let you step through a handler line by line as it runs, inspect the values of variables, and trace the flow of messages. To debug a handler, follow these steps:
Step (Command-S)Runs the current statement and moves to the next one. If the current statement calls another message or function handler, Step does not switch to the new handler and step through it. It just gets the result of that call. Step Into (Command-I)Runs the current statement and moves to the next one. If the current statement calls another message or function handler, Step Into does switch to the new handler so you can step through it. TraceRuns through the rest of the statements one line at a time, but without pausing after each statement. If the current statement calls another message or function handler, Trace does not switch to the new handler and trace it. Trace Into (Command-T)Runs through the rest of the statements one line at a time, but without pausing after each statement. If any statement calls another message or function handler, Trace Into will switch to the new handlers and trace them as well. Go (Command-G)Runs the remainder of the script from the current statement without stepping. After a Go command, HyperCard leaves the Script Editor window open, but activates the window containing the current card. Trace Delay...Displays a dialog box in which you can specify the number of ticks that HyperCard will pause between each statement as it traces a handler. Set Checkpoint (Command-D)Places a checkpoint at the current line of a handler. This command changes to Clear Checkpoint if you’ve already set a checkpoint on the line. Abort (Command-A)Stops the script from running. After an Abort command, HyperCard leaves the Script Editor window open and active. Variable WatcherShows or hides the Variable Watcher, a window that allows you to inspect the values of parameter variables or global and local variables as they are set during the execution of a handler. To change the value of a variable using the Variable Watcher, click to select a variable. Its value appears in the bottom panel. Edit the value and press Enter to save it. Click Tips for information about Variable Watcher properties. Message WatcherShows or hides the Message Watcher, a window that allows you to watch what messages HyperCard sends as it runs the script. For example, if you step through a statement such as Click Tips for information about Message Watcher properties. PlaceholdersRelated Topics
|
Version 0.7b1 (March 24, 2022)