User Guide
Debugging your scripts 159
To display a movie clip’s properties in the Debugger:
1.
Select a movie clip from the display list.
2.
Click the Properties tab in the Debugger.
To modify a property value:
• Double-click the value, and enter a new value.
The value cannot be an expression. For example, you can enter
50 or "clearwater", but you
cannot enter
x + 50. The value can be a string (any value surrounded by quotation marks [""]), a
number, or a Boolean value (
true or false). You can’t enter object or array values (for example,
{id: "rogue"} or [1, 2, 3]) in the Debugger.
For more information, see “String operators” on page 53 and “Using operators to manipulate
values in expressions” on page 49.
Note: To write the value of an expression to the Output panel in test mode, use the trace statement.
See “Using the trace statement” on page 165.
Setting and removing breakpoints
A breakpoint lets you stop a SWF file running in Flash Player at a specific line of ActionScript.
You can use breakpoints to test possible trouble spots in your code. For example, if you’ve written
a set of
if..else if statements and can’t determine which one is executing, you can add a
breakpoint before the statements and step through them one by one in the Debugger.
You can set breakpoints in the Actions panel or in the Debugger. (To set breakpoints in external
scripts, you must use the Debugger while in a debugging session.) Breakpoints set in the Actions
panel are saved with the FLA file. Breakpoints set in the Debugger are not saved in the FLA file
and are valid only for the current debugging session.