Set Properties and Format Fields

19-8 Oracle Reports Users Guide to Building Reports

4. In the Object Navigator, click the F_CREDITLIMIT node, then Ctrl-click F_

AMOUNT to select both nodes. 5. Click the Paper Design button in the toolbar to make the Paper Design view the active window, with the F_CREDITLIMIT and F_AMOUNT fields selected, and make the format changes you can also click the corresponding buttons in the toolbar: ■ choose Format Number Currency ■ choose Format Number Add Decimal Place ■ choose Format Number Add Decimal Place again, for two decimal places ■ choose Format Justify Right 6. In the Paper Design view, click the Amount label column heading, and choose Format Justify Right .

19.6 Create New Fields

To create new fields for the page numbers of the report: 1. Click the Paper Layout button in the toolbar to display the Paper Layout view. 2. In the Paper Layout view, click the Edit Margin button in the toolbar to display the margin areas of your report. You will be creating two page number fields in the top margin, as shown here: Figure 19–6 Page number source fields in top margin of report

3. Click the Field tool in the tool palette and draw a field about two characters long

in the center of your margin.

4. Double-click the new field object F_1 to display the Property Inspector, and set

the following properties: ■ Under General Information, set the Name property to F_TOTAL_PAGENO. ■ Under Field, set the Source property to Total Pages, and set the Visible property to No. ■ Under General Layout, set the Horizontal Elasticity property to Variable. Hiding both this field and the field youll create below ensures that theyll appear only where you reference them. Changing the horizontal sizing to Variable ensures that the fields can expand to accommodate large page ranges. ■ Under Field, click the Page Numbering property field to display the Page Numbering dialog box: In the Reset at list, click R_G_ENAME, and verify that the Start at and Increment by values are both 1, then click OK. 5. Close the Property Inspector. Building a Report that Renumbers Pages by Repeating Frame 19-9 6. In the Paper Layout view, click the F_TOTAL_PAGENO field.

7. Choose Edit Copy, then choose Edit Paste to create a new field with the same

dimensions as F_TOTAL_PAGENO next to F_TOTAL_PAGENO. 8. Drag the new field object F_TOTAL_PAGENO1 to an open area of the margin. 9. Double-click the new field object F_TOTAL_PAGENO1 to display its Property Inspector, and make the following changes: ■ Under General Information, set the Name property to F_PAGENO. ■ Under Field, set the Source property to Page Number. Because it is a duplicate of F_TOTAL_PAGENO, the Horizontal Elasticity and Visible properties are already set as desired. ■ Under Field, click the Page Numbering property field to display the Page Numbering dialog box. In the Reset at list, click R_G_ENAME, and verify that the Start at and Increment by values are both 1, then click OK. 10. Close the Property Inspector. Next, you will reference these fields in a text box to display page numbers in the format Page X of Y Pages.

19.7 Reference Fields

To reference the page number fields: 1. In the Paper Layout view, click the Line Color tool in the tool palette.

2. In the color palette, click No Line.

3. Click the Text tool in the tool palette. 4. Position the cursor in the top margin where you would like the page number to appear, and click to create a boilerplate object. 5. In the new boilerplate object, type Page F_PAGENO of F_TOTAL_PAGENO. Figure 19–7 Page number source and reference fields in top margin of report In the report output, the current page number will appear where you reference the field F_PAGENO, while the total number of pages for each master will appear where you reference the field F_TOTAL_PAGENO. If you wish, you can resize the