Debugger action to take. Can be one of the following values:
Ask if Debugger is on
Turn off Debugger
Turn on Debugger
Forces the application to break in the Xbasic debugger.
The DEBUG() function is used to turn on or off the Alpha Anywhere Debugger. The Debugger is used to trace through an Xbasic script, to watch the flow of execution. You can use the Debugger to find run-time errors and logical errors in your scripts. For more information, see "Finding Errors in Scripts".
Use the On/Off Switch parameter to turn the Debugger on or off. To turn on and display the Debugger window, use debug(1). To close the Debugger window, use debug(0).
When running this script, the Debugger will appear after the word "Start" is printed to the Trace window.
function process as C (param as N) select case param = 0 process = "Zero" case param = 1 process = "One" case param = 2 process = "Two" case else process = "Error" end select end function dim result as C trace.writeln("Start") debug(1) x = 0 for x = 1 TO 10 y = mod(x,3) result = process(y) trace.writeln(result) next x trace.writeln("End")
Developer Environment Only