views:

28

answers:

1

I'm trying to debug AS3 code on production. I have no access to trace(), can't write to disk or open a socket. What I want is to display something on screen.

With AS2 I could just access _root and create a text field with my trace data.

Any ideas how I can pull this off with AS3? My class extends Object, it is not a sprite and is never added to a parent display object.

Thanks! :)

+1  A: 

Why can you not use trace?

You could download the Flex SDK ( http://opensource.adobe.com/wiki/display/flexsdk/Downloads ) and in the "bin/" folder is a program called "fdb" (Flex DeBugger) which is a command line tool for debugging .swfs.

Once downloaded, open up a terminal/cli, navigate to the "bin/" folder, and issue the command fdb http://example.com/index.html (./fdb http://example.com/index.html on a Mac) and the debugger will connect, assuming it's a debug .swf you've uploaded.

Fdb will also allow you insert break-points, watch/print/change variables etc. It's a very handy tool.

Joony
it's also more or less impossible to deploy if you need to solve something that's installed onsite somewhere in something like a kiosk or similar.
grapefrukt