Previous | Table of Contents | Next

Page 486

FIG. 18.12
The General Layout tab.



FIG. 18.13
Program Unit editor window.


To use the program unit editor window, type in the code you want for the format trigger then press the Compile button. This verifies that your code is syntactically correct. If you make a change then decide that it isn't what you want you can click the Revert Button and revert the code back to the way that it was before you put in the new code. After you compile, click the Close button to go back to the Layout Editor.

The next section is the Print Condition section, which governs how and when objects print. Type is when an object prints, and Object is how the object prints. The choices for Type are: First, All But First, All But Last, All, and Default.

Page 487

The last section is the Sizing section. The Sizing of an object determines how an object sizes depending on the data returned to it. You have four choices for Horizontal and Vertical: Contract, Expand, Fixed, and Variable.

Boilerplate objects should never have any sizing other than Fixed both Horizontal and Vertical. All objects contract from the bottom right to the upper left. This is very important when you are dealing with the space in a report.

Printer Codes and Comments TabsThe Printer Codes tab allows you to send special printer instructions before and after the object is printed. Figure 18.14 shows the tab.

For specifics on the codes, refer to your printer manual, as each printer has different codes. This is only suggested for advanced users that need other fonts or print styles.

FIG. 18.14
Printer Codes tab.


The Comment tab is a large text field in which you can document the object. Figure 18.15 shows the tab.

Page 488

FIG. 18.15
Comment tab.


Special Tabs

Repeating frames and fields have another tab, the Object tab. This tab allows you to set specific properties for the objects.

Repeating Frame Object TabSource is where you assign a frame to a group in the query.

The last section is Spacing. You can set in units how much space should print between instances of the repeating frame. The units are the units for the report. You can set both horizontal and vertical spacing. Figure 18.16 shows the dialog box.

Field Object TabThe Field Object tab (see Figure 18.17) has two sections: Source and Display. In the Source section, you specify from the drop-down list which database, formula, or summary column the field should display. In the Display section, you can select a format mask for a field if it is of type number. You can set the Minimum Widow Lines, if you only want a certain number of lines to print on a page initially. By clicking the box next to Hidden, you are saying that the field should not print when the report is run.

Page 489

FIG. 18.16
Repeating Frame
Object tab.



FIG. 18.17
Field Object tab.


The Page Number button is unavailable unless you give the field a source of &Logical Page Number, &Panel Number, or &Physical Page Number. These are report functions that return the logical page number, the panel number, or the physical page number. Figure 18.18 shows the Page Number dialog box. You can select by clicking the check boxes to include the header page, the body pages, and the trailer pages. You can set what number the pages should start at as well as how they should increment. You can also set a reset point for the numbering. This is useful if you want each break section of a report to have its own page number sequence.

FIG. 18.18
Page Number
dialog box.


Page 490

Making a Report Presentable

The Default Layout Editor is the best place to start a report. The default layout is very basic and generally considered ugly when it comes to presentation, but because of the frames it is the best place to start. Until you fully understand how frames work it is best to start the report from the default and then make improvements from there.

Some of the improvements that you might want to make include the following.

Changing the Fonts of Different Objects

To change the font of an object or several objects, select the object(s) by clicking the first and shift-clicking any others. Then from the Format menu, select Font. Select the font style, size, or color that you want and click OK to apply the changes.

Changing the Text of the Column Headings

To change the text or boilerplate labels that were created, select the object, then click the Text tool on the Tool Palette (the capital T), and then click inside the boilerplate object. This opens up the object for changes. Type whatever you want, even if the boxes don't appear big enough; you can resize it later. Then click outside the box to close it. To make the boilerplate bigger, click on the handles and drag to the appropriate size.

Removing the Dotted Line or Changing the Line

To remove the dotted line that serves as a separator between the column headings and the data, click the object and then click the Delete key. If you want to change it or resize it, it is a boilerplate text object so follow the preceding steps.

Adding a Report Title

To add a report title that will appear on every page, you need to switch to the margin view of the report by clicking the Margin button on the toolbar. To create space to add your report title, click inside the body outline then drag the handle down until you have enough space. Now you can add whatever you want for the title. Figure 18.19 shows the margin window for the report.

Adding Page Numbers or a Report Date

In the margin of the report, you may also want to add page numbers or a report date. To do this, create a field by using the field tool from the tool palette (the abc icon). Open the property sheet and give the field a source of one of the following: &Logical Page Number, &Panel Number, or &Physical Page Number. You will almost always use &Logical Page Number. The Page Numbering button is now available. Set any options in the dialog box then click OK to apply them. To add a report date of the current system date, create a field, give the field a source of &Current Date, and then select a format mask for the date. These two examples may be added anywhere in the report; they don't have to be in the margin.

Previous | Table of Contents | Next