Comments and Examples
For debugging purposes, it is often helpful to have information about which lines are being executed and in which order. At a point where trouble is anticipated in a program, the programmer can insert the statement
01230 TRACE ON
To start the display of line numbers. Later, the following statement can cancel this feature:
01400 TRACE OFF
The TRACE display runs swiftly and is quickly lost from the screen. The following example will send TRACE output to the printer:
01240 TRACE PRINT
- 1.) ON.
"ON" initiates TRACE mode; it starts a display of line numbers on the screen.
"OFF" cancels the display of line numbers.
"PRINT" directs TRACE output to the printer.
- 1.) Trace mode may also be initiated, terminated, and directed to the printer with options on the run command and the go command.
To redirect the output to a file you can use a command similar to:
run trace print >trace.txt
Unfortuantely this can not currently be done with the go command.