Debugging a macro
When a macro didn't go according to plan, you need to determine what exactly causes the macro to fail. The Script Editor provides the debugging feature allows you to observe and correct the errors in a macro. To activate the debugging feature, you just play the macro in Script Editor.
Running Macro in Debug Mode
To debug the macro, you should launch the macro in the debug mode. You just open the macro in Script Editor, then select the menu Play, next select Play, or press F5. In the debug mode, you can see the playback on the Play Log pane.
A breakpoint pauses the macro execution immediately before the breakpoint line. Breakpoints can be set whether the macro is running or not. Once a breakpoint is set, the breakpoint icon will appear next to the line number of the step. To set a breakpoint, do the following:
Breakpoints are used to pause macro execution in order to give you a chance to inspect the state of the action at that point. When execution stops at a breakpoint, you can control execution by using any of the following on the menu Play or toolbar.
Local variables and global variables can be inspected through the User Variables pane and Global Variables pane. To inspect variables:
During execution, the debugger will pause at the line with the breakpoint. Once execution is paused, variables in User Variables pane and Global Variables pane can then be inspected.