• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL

Chapter 16. Debugging a Movie > Using the Flash Debugger

Using the Flash Debugger

Flash provides several tools for testing ActionScript in your SWF files. The Debugger panel lets you find and locate errors hidden in an .swf file, while it’s running in the Flash Player. You must view your SWF file in a special version of Flash Player called the Flash Debug Player (installed automatically when you install the Flash application). The Debugger panel, shows a hierarchical display list of movie clips currently loaded in the Flash Player. You can then use the Debugger to display and modify variables and property values as the .swf file plays. In addition, you can insert breakpoints to stop the .swf file and step through the ActionScript code line by line. In fact, you can even use the Debugger panel to test files on a Web server in a remote location. The Debugger lets you set breakpoints in your ActionScript that stop the Flash Player, and then lets you step through the code as it runs. You can then go back to your scripts and edit them so that they produce the correct results. The Debugger will show you where the problems are, but it doesn’t fix them.

Use the Flash Debugger

Click the Control menu, and then click Debug Movie.

The Code View panel displays a message indicating the movie is paused.

Click the Continue button to start the movie.

Click the Stop Debugging button to turn off the Debugger panel.

Click inside the code, and then click the Toggle Breakpoint button to add or remove a breakpoint at the insertion point of the cursor.

Breakpoints stop the movie from playing and allow you to step through the code line by line.

Click the Remove All Breakpoints button to remove all the breakpoints from the code.

Click the Step Over, Step In, and Step Out buttons to step through each line of an ActionScript.



Not a subscriber?

Start A Free Trial

  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint