Progress
Report Builder
Tutorial


Inserting New Fields

To display the information calculated by the Address–All and Page–Total fields, insert them on the report layout. Because Report Builder places fields in the report layout at the edit cursor location, position the cursor at the correct location before inserting the field.

Address–All Field

The logical place to insert the Address–All field is between the Name and Balance fields on the record band line. However, to position the Address–All field correctly, you must first move the balance information to the right.

Follow these steps to move the customer balance information and insert the Address–All field:

  1. Select the Balance text field and the three fields directly below it. These three fields are the Balance data field, the text field that contains the total line, and the GrSum1 field.
  2. Drag the fields so that their right edges are at the 7.5-inch mark, placing all the balance information along the right page margin. Make sure that the fields are still on the same band lines. The layout with the fields repositioned looks like this:
  3. Deselect the fields by clicking an empty part of the layout.
  4. Choose Edit Insert Field, click the right mouse button, or press INSERT. The Insert Field dialog box appears.
  5. Position the edit cursor at the 2-inch mark on the record band line. If the Insert Field dialog box covers this area of the report layout, move it to another part of the screen.
  6. Activate the Include Field Label toggle box:
  7. Select the Address–All field from the selection list. If the Address–All field does not appear in the Field List when the Insert Fields dialog box appears, double-click User Defined Fields, then Calculated Fields from the Database/Table Selection list. The Address–All field appears in the Field List:
  8. Choose Insert. Report Builder inserts the field on the record line and the “Address–All” label on the page header band line.

When you complete these steps, the Address–All field should appear on the record band line and the text string “Address–All” should be the field label, as shown in Figure 4–2.

Figure 4–2: Layout with Address–All Field

Page–Total Field

After you insert the Address–All field, the Insert Field dialog box remains open to allow you to insert additional fields.

Follow these steps to insert the Page–Total field:

  1. Position the edit cursor directly below the GrSum1 field on the second line of the page footer band line. GrSum1 is the aggregate field Report Builder created to total the Balance field for the report.
  2. Because you selected a calculated field in the previous task, the Insert Field dialog box still displays the calculated fields available for the report.

  3. Select Aggregate Fields from the Database/Tables selection list.
  4. Select the Page–Total field from the Field selection list.
  5. Deactivate the Include Field Label toggle box.
  6. Choose Insert, then Close.
  7. Choose the Line button on the format bar. The cursor changes to a crosshair.
  8. Draw a “total” line directly above the Page–Total field.
  9. Deselect the line.

Figure 4–3 shows how the report layout looks now.

Figure 4–3: Layout with User-defined Fields

The Address–All field overlaps the Balance field because the default format for the Address–All field is very long in order to accommodate all the address fields. Your next task is to change the Address–All field’s width and alignment so that the customer’s address does not appear on top of the customer’s balance.


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