Lesson8.10.Working with Section Properties


Lesson 8.10. Working with Section Properties

Figure 8-21. The Sorting and Grouping dialog box


Figure 8-22. The . You can learn more about its options in Table 8-6.


When you want to fine-tune how a group or section works, there are two different places to go:

  • The Sorting and Grouping dialog box: Contains important sorting and grouping settings, such as if you want your report to display any Group Headers and/or Footers. To display the Group Properties dialog box, click the Sorting and Grouping button on the toolbar.

  • The : Contains miscellaneous properties for each report section, such as the section's background color. To display the properties or settings for a report section, click the section divider line and then the Properties button on the toolbar, or right-click the section divider line and select Properties from the shortcut menu, or double-click the section divider line.

Some of the settings you might want to adjust might be the Group Interval property (especially for sections grouped by date fields) and the Force New Page property, which tells Access to start a new page before or after each report section. In this lesson you will learn how to tweak your report section settings.

  1. Double-click the rptSalesByMonth report to open it in Print Preview.

    In this report Access uses the Date field to group recordsAccess creates a Date group for each Date value, or day. The report would be meaningful if Access grouped dates by month. Before we can change the report, we need to switch to Design view.

  2. Click the View button on the toolbar to switch to Design view.

    You can change the grouping interval to specify how records are grouped in a report in the Sorting and Grouping dialog box.

  3. Click the Sorting and Grouping button on the toolbar.


    Tip: Another way to sort and group is to select View

    The Sorting and Grouping dialog box appears, as shown in Figure 8-21. The Group On property lets you specify how you want to group records. For example, you can use the Group On property to group a Date field by year.

    Let's change the Date Group Interval so that the report groups sales on a monthly basis.

  4. Click the Date field, click in the Group On box in the Group Properties section, select Month from the list, and then close the dialog box.

    You won't be able to see any of the grouping changes until you display the report in Print Previewand we'll do that in a minute. Every report section has its own set of properties or settings that you can view and change. You can view the properties for a report section by double-clicking the section's divider line.

  5. Double-click the Date Header section divider line.

    Access displays the properties for the Date Header section, as shown in Figure 8-22. Table 8-6 describes these options in more detail.

  6. Click the Format tab.

    We want to change the background color of the . Here's how to do it.

  7. Click the Back Color box, click the button, select a gray color and click OK, then close Section Properties dialog box.

    Let's see how the modified report looks.

  8. Click the View button on the toolbar to display the report in Print Preview. Scroll through the report's pages and notice how the Date Section is now grouped by month.

  9. Click Close, save your changes, and close the report.

Table 8-6. Important Section Properties

Property

Description

Force New Page

Allows you to tell Access to start a new page before or after this whenever the group changes.

New Row Or Col

Works the same as the when you're printing a report in columns.

Keep Together

Used to specify whether you want to allow Access to put breaks when they occur naturally (No) or forces Access to keep the entire on one page when possible (Yes).

Visible

Used to specify if you want to see the section (Yes) or not (No). Hiding a report's Detail Section is useful when you want to create a summary report that uses a Group Footer to total database information without displaying the individual records.

Can Grow

Used to specify whether the section can grow larger to accommodate more data in the last field in the section (the field control Can Grow property must also be set to Yes).

Can Shrink

Enables the section to grow smaller if the extra space is not needed. (Used in conjunction with the Can Shrink property for a field control.)

Repeat Section

When a group is split across several pages, use the Repeat Sections property to specify whether or not Access should repeat the heading on the new page.

Height

Access automatically sets this property as you drag the section divider up or down on the screen. You can specify an exact size (for example, if you want the section to be precisely three inches tall) by entering it here.

Back Color

Used to specify the color of the section. Click the button to select the color.

Special Effect

Adjusts the visual effects for the section. Your choices are limited to Flat (the default setting), Raised, or Sunken.


QUICK REFERENCE

TO MODIFY A REPORT'S SECTION AND GROUPING OPTIONS:

  1. DISPLAY THE REPORT IN DESIGN VIEW.

  2. CLICK THE SORTING AND GROUPING BUTTON ON THE TOOLBAR.

TO MODIFY A SECTION'S PROPERTIES:

  1. DISPLAY THE REPORT IN DESIGN VIEW.

  2. DOUBLE-CLICK THE SECTION LINE FOR THE SECTION WHOSE PROPERTIES YOU WANT TO VIEW/MODIFY.




CustomGuide Inc - Access 2003 Personal Trainer
Access 2003 Personal Trainer (Personal Trainer (OReilly))
ISBN: 0596009372
EAN: 2147483647
Year: 2005
Pages: 209

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net