Progress
Debugger Guide


Using Buttons

To execute a button definition, click on the corresponding button in the button panel. However, first ensure that values are selected in the listing panel for any Debugger variables in the button definition. (This includes any variables in macros that are part of the button definition.) For example, suppose you define a button using the SetAndGo macro defined in the "Using Macros" section.

button " Set and Test " SetAndGo; show stack 

This button sets a breakpoint on the selected line of a procedure, runs the procedure, and displays the procedure call stack at the first breakpoint. To use this button with line 16 of arrmenu.p, you must perform the following steps:

  1. Ensure that arrmenu.p is displayed in the listing panel using the FILE command. This provides the value for the &FILE variable, arrmenu.p.
  2. Place the text cursor in the listing panel on line 16 of the procedure. This selects and provides the value for the &LINE variable, 16.
  3. Click on the Set and Test button in the button panel. This sets the breakpoint on line 16 of arrmenu.p, runs the procedure, and displays the procedure call stack at the first breakpoint.
Specifying Button Parameters

In general, each Debugger variable in a button definition takes its value from the contents of the listing panel when you choose the button. You can use the techniques described in Table 5–6 to assign values to these variables in the listing panel.

Table 5–6: Variable Values in Buttons 
Variable
To Assign the Value from the Listing Panel
&FILE
  • Enter the FILE, UP, or DOWN command. The value is the name of the listed procedure.
  • Interrupt an application with a breakpoint or the break interrupt function. The value is the name of the interrupted procedure.
&LINE
  • Click the mouse anywhere on a listing line, leaving the mouse cursor on the line. The value is the number of the selected listing line.
  • Use the mouse to select any text on the line (see &TEXT). The value is the number of the line where text is selected.
&TEXT
  • Place the mouse pointer on the text, and double-click to select a space-delimited string. The value is the space-delimited string selected with the mouse. This technique does not work in Windows and does not work in Motif for strings surrounded by quotes or other punctuation; instead, use the following technique.
  • Drag the mouse pointer from the first to the last character of the selected string. The value is the string included in the mouse selection. Use this technique to include spaces or to omit surrounding quotes or other unwanted characters from the selection.


Copyright © 2004 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095