16. Specify the control fields  (Required for subtotaling)

The Control Field selection on the Design menu specifies the total control breaks on the report.  Each field specified is a separate control break.  When a control field changes its value, any designated subtotals are printed.  The Control Field Definition window is used to specify the control fields.

At the Add menu, move the cursor to the Return option and press the Return key.  Move the cursor to Control Field and press the Return key.  The Control Field Definition window will appear as shown in Figure 15.

For Source, enter the designator of the Data Set or DI of the field.  For Control Field(s), enter the name of the field. In the example, Main is the source and TITLE_CODE is the control field.  Subtotals will appear each time the title code changes.

Both the Source and the Control Field can be selected from a list by positioning the cursor on the item and pressing the Slash key ('/').  A list of names will appear.  Move the cursor to the desired name and press the Return key.

After entering the control fields, move the cursor to the Return item on the Select an Action menu and press the Return key.  Control is returned to the Design menu.

Figure 15 Control Field Definition screen

17. Use the View selection to see the layout  (Optional but recommended)

On the Design menu, move to cursor to the View item and press the Return key to see the format of the report lines (Figure 16).  After examining the report, move the cursor to the Return item on the Select an Action menu and press the Return key.  Control is returned to the Design menu.

Figure 16 Viewing The Report Line Layout screen