IBM AS/400 Frozen Dessert Maker User Manual


 
Setting and Removing Breakpoints
5. After the breakpoint is set, press F12 (Cancel) to leave the Work with Module
Breakpoints display. Press F3 (End Program) to leave the ILE source
debugger. Your breakpoint is not removed.
6. Call the program. When a breakpoint is reached, the program stops, and the
Display Module Source display is shown again. At this point you can step
through the program or resume processing.
Example of Setting a Conditional Job Breakpoint Using the
BREAK Command
In this example, we want to stop the program when the date field BigDate has a
certain value. To specify the conditional job breakpoint using the BREAK command:
1. From the Display Module Source display, enter:
break 128 when BigDate='1994-09-30'
A conditional job breakpoint is set on line 128.
2. After the breakpoint is set, press F3 (End Program) to leave the ILE source
debugger. Your breakpoint is not removed.
3. Call the program. When a breakpoint is reached, the program stops, and the
Display Module Source display is shown again.
Display Module Source
Program: DEBUGEX Library: MYLIB Module: DBGEX
122
123 *---------------------------------------------------------------
124 * After the following SETON operation, *IN02 = '1'.
125 *---------------------------------------------------------------
126 C SETON
127 C IF *IN02
128 C MOVE '1994-09-30' BigDate
129 C ENDIF
130
131 *---------------------------------------------------------------
132 * Put a new value in the second cell of Arry.
133 *---------------------------------------------------------------
134 C MOVE 4 Arry
135
136 *---------------------------------------------------------------
More...
Debug . . . break 128 when BigDate='1994-09-30'______________________________
_______________________________________________________________________________
F3=End program F6=Add/Clear breakpoint F10=Step F11=Display variable
F12=Resume F17=Watch variable F18=Work with watch F24=More keys
Figure 83. Setting a Conditional Job Breakpoint Using the BREAK Command
National Language Sort Sequence (NLSS)
Non-numeric conditional breakpoint expressions are divided into the following two
types:
Char- 8: each character contains 8 bits
This corresponds to the RPG data types of character, date, time, and
timestamp.
Char-16: each character contains 16 bits (DBCS)
Chapter 11. Debugging Programs 183