Entering the Debugger

When a program is executed in debug mode, the debugging window pops up over the lower portion of the screen. Commands to the debugger and their results are displayed in this window. You can control the size of the command window from within the debugger by pulling down the Source menu and selecting Window Size.

If you are running the debugger under Windows, you can change the size of the entire debugger window. Point to a border or corner, and when the mouse pointer changes into a double arrow, hold the mouse button down and drag the border or corner to reach the size you want. Release the button when you are ready.

You can enter the debugger in several ways; the most common is to specify the -d option to runcbl. Here's a list of all the ways the debugger can be entered initially:

Note: If you receive the following message when entering debug mode, it is indicating that the program has somehow started multiple OS threads, which is currently not supported. You must figure out how the multiple OS threads have been spawned, and prevent them before you can debug the program:

Multiple OS threads detected

If you have already entered the debugger, you may reenter it in one of the following ways:

Each of the situations described above causes the debugging window to pop up over the lower portion of the screen. If source-level debugging is being used, then the upper half of the screen displays the source at the location currently being executed. When the debugger exits, these windows are removed and the application screen is restored. The application screen is not restored, however, until an ACCEPT or DISPLAY verb is executed. This allows you to debug a section of code without the distraction of having the screen being constantly repainted.