Checking syntax and punctuation

To thoroughly determine whether the code you wrote performs as planned, you need to publish or test the file. However, you can do a quick check of your ActionScript code without leaving the FLA file. Syntax errors are listed in Output panel. (When you check syntax, only the current script is checked; other scripts that may be in the FLA file are not checked.) You can also check to see if a set of parentheses, curly braces, or brackets (array access operators) around a block of code is balanced.

To check syntax, do one of the following:

To check for punctuation balance:

  1. Click between braces ({}), array access operators ([]), or parentheses (()) in your script.
  2. Press Control+' (Windows) or Command+' (Macintosh) to highlight the text between braces, brackets, or parentheses.

    The highlighting helps you check whether opening punctuation has correct corresponding closing punctuation.