4. Perform Traces in Scripts

The Trace command can be used in Basic Control Engine scripts to print output to the Program Editor window's Trace section.

Enable tracing.

Clear trace results.

Disable tracing.

  1. Enable Tracing

  1. Enter a Trace command in a script.

Example

Trace "TANK750 " & MyPoint.Value

  1. Do one of the following.

1

Depress the Trace button on the Application toolbar.

2

Click Debug>Trace on the Program Editor menu bar.

3

Press Alt+D+R on the keyboard.

Trace is enabled.

  1. Run the script.

Result: The trace results display in the Program Editor window trace section.

  1. Clear Trace Results

Do one of the following.

A

Click the Clear Trace button on the Application toolbar.

B

Click Debug>Clear Trace on the Program Editor menu bar.

C

Press Alt+D+L on the keyboard.

Result: The trace results are deleted from the Program Editor trace section.

  1. Disable Tracing

Do one of the following.

A

Restore the Trace button on the Application toolbar.

B

Click Debug>Trace on the Program Editor menu bar.

C

Press Alt+D+R on the keyboard.

Result: The trace entries are ignored when the script is run.

More information

Debug scripts.