2019.1

Table Of Contents
When execution is suspended the list includes the current call stack, including line numbers.
From top to bottom, frames are ordered from new to old. The current stack frame has an arrow
indicator. You will only see multiple stack frames if execution is suspended inside a function.
You can click a frame to make it the current frame. The Variables panel always reflects the state
of the current frame.
Source code
You can click any script at the left to view it in the source editor at the top right. An instruction
pointer in the left margin marks the current line.
The code is read-only, but clicking to the left of a line of code adds a breakpoint to it (except
when a line only contains a declaration). Note that breakpoints are discarded when the dialog
is closed.
Hovering over a variable in the code shows a tooltip with the value of that variable. The
variable can be nested, like fields in record.fields.
Variables
At the bottom right the Script Debugger shows a hierarchical overview of all local and global
variables and their state. This information is always relative to the current stack frame, which is
the one that's selected on the left.
The overview includes the special entry "(this)", which represents the JavaScript "this" object.
If the current script is not a Control Script, the overview also includes the special entry "
(resource)". When expanded, this entry shows the HTML of the current Master Page or section,
allowing you to see exactly how each line in the script affects the DOM.
Use the Copy button (or press Ctrl+C) to copy the label and contents of the selected variable
and all of its children to the clipboard.
Expressions
You can add custom expressions at the top of the list of variables. This is especially useful
when you want to monitor the value of a variable that is situated at a lower level in the
hierarchy. For example, if you'd want to directly see the height of the top margin of a section as
you step through the code, you could add the following expression:
merge.section.margins.top.
Expressions can include function calls. For example, you could monitor the height of an
element that has the ID my_div with the expression: query("#my_div").height(). Note that the
query in this example will be limited to the current resource (Master Page or section).
You could also change the value of a variable through an expression to see how that affects the
Page 473