Step 4 Read the error messages in debug session
OK, new lest’ test the bug in the app.
We know there is a bug in b2_click() function, let’s see it in action.
Click on “Button 2”, this will call b2_click() function, and app will stop at the error.
Take a close look at the Debug tab, in here it tell you what is the error, and who is calling.
here is what is display in the Console tab, it tell you more information about the error and line number where error occur
Step 5 Change values of variable
You can always change the value of variable, while the application is suspended, here is an example, if I want to change button2.label from “num = 10” to “new label”, here is how to do it.
First find the variable label, right click , select Change Value,
Set Value window pop up, and display the current value,
I am change that string to my new string “new label”, than press OK
now in the Variables tab, the new value is set.
Resume the application, label is updated.
Conclusion
all right, now you know how to using the debugger!
Here is a quick summary
Double click Create a breakpoint,
click on the bug icon start debug mode,
trigger the action to suspend the application
variables tab tell you what is the value
console tab tell you what and where is the error if any
debug tab tell you who called who and who did what,
and waiting for you to tell it what next action is.
If you think you are ready to testing your debug skill now, go try it on you own application now.
If not goto line 1.
Here is a tip for who is new to Flex.
remember always export a release build, not the debug build, which is much bigger.