In Flex Builder 2.0, when you click Debug or Run, Flex Builder launches the Flash Player. But which Flash Player?
By default, it launches your system’s default web browser. However, you can change that if you need to.
If you go to Window > Preferences, General, Web Browser, you will see a preference for which browser to use. This preference controls which browser to use for everything in Eclipse, not just which browser to use for Flex Builder’s debugging. For example, it controls which browser will be used if you double click on a .html file in the Navigator view.
But there is another option. I often like to use the standalone Flash player (SAFlashPlayer.exe), because it launches a bit faster than the browser. There are times when you really need your Flash app to be running “in context” inside an HTML page, such as when the Flash app and the JavaScript on the page are interacting with each other; but if that is not the case, then you might like debugging with the standalone Flash player.
Doing that is easy, although not obvious: Go to the Run > Debug… dialog, and
change the launch URL so that it ends with .swf
instead of .html
. For
example, if the URL is C:\MyProject\MyProject-debug.html
, change it to
C:\MyProject\MyProject-debug.swf
.
Note that this only works for local URLs. HTTP and HTTPS URLs always cause a web browser to run, never the standalone Flash player.
Click for an example: