|Oracle® Fusion Middleware Oracle Reports User's Guide to Building Reports
11g Release 1 (11.1.1)
Part Number B32122-01
The steps in this section will show you how to add boilerplate text to your report layout that will display when no records are retrieved.
To add boilerplate text:
In the Paper Layout view, click the Confine Off and the Flex Off buttons in the toolbar.
Note:To adjust the way the boilerplate objects display in your resulting report, you must turn off Confine and Flex modes before you create the objects.
Click the Text tool in the tool palette.
Draw a rectangle above the two fields F_ENAME and F_JOB to create a new boilerplate text object.
Click in the boilerplate text object, and type "
No detail records retrieved."
Select the text, then choose Format > Font.
In the Font dialog box, choose Arial, then click OK.
While the Paper Layout view still displays, click the Object Navigator and position the two windows so that you can see them side-by-side.
In the Object Navigator, navigate to M_G_DEPTNO1_GRPFR, and select these objects using CTRL-click:
Your Object Navigator should look like this:
Figure 21-6 Selected objects in the Object Navigator
In the Paper Layout view, click the Confine On button in the toolbar.
Choose Layout > Bring to Front.
Note:If this menu option is greyed out, click the title bar of the Paper Layout view, but do not click on the canvas itself. This menu option is only available when the Paper Layout view is active.
By choosing this menu option, Reports Builder will display the records in front of the boilerplate text you just created. If there are no records, the boilerplate text will display.
The Object Navigator should now look like this:
Figure 21-7 Selected objects brought forward in the Object Navigator
Note:You will notice that the boilerplate text, B_1, is now located directly under the parent frame, M_G_DEPTNO1_GRPFR. This placement means that the records displayed by the objects in the repeating frame, R_G_DEPTNO1, will display in front of the boilerplate text. The boilerplate text, which says that no detail records were retrieved, only displays when no records are present.
Now, we need to change the fill color of the parent frame, so that you cannot see the boilerplate text behind the detail records.
In the Object Navigator, click M_G_DEPTNO1_GRPFR so that it is the only object selected. In the Paper Layout view, you should see this same frame selected.
Click the Fill Color tool in the tool palette, and change the fill color to light blue, so that it matches the template.
Click the Paper Design button in the toolbar to run and display your report in the Paper Design view. Your report should look something like this:
Figure 21-8 Final Paper Output of the Suppressing Labels Report
Note:Notice how the record for Department 40 shows the boilerplate text you added, and the field names for the record are suppressed.
Save your report as