Understanding the Relationship Between Forms and Reports

The final product of most database applications is a report. Access combines data from tables, queries, and in some cases forms to produce a report that you can print for people who need or request it. One of Access's major selling points is its capability to generate fully formatted reports easily and quickly. No other report generator application has even come close to rivaling Access's flexible report-generation capabilities.

With the expansion of email and the growth of intranets and the Internet, it's becoming more common for people to read and, when necessary, print their own reports. Access offers the following methods of distributing paperless reports:

  • Report Snapshots are self-contained files that you can send as an email attachments with Outlook, Outlook Express, or any other Windows email program. Users must have a local copy of the freely distributable Snapshot Viewer application to open and print the reports, which are exact replicas of the conventional Access report. You can provide copies of the Snapshot Viewer to users or they can download the Viewer from the Microsoft Web site.

    For more information on Report Snapshots, see "Mailing Report Snapshots," p. 696.


  • graphics/2002_icon.gif Static Web reports apply an Extensible Stylesheet Language Transformations (XSLT) document to an Extensible Markup Language (XML) file to generate an HTML 4.0 simulation of the original report. You can export static also called snapshot Web reports to a Web server from conventional (Jet) applications or Access data projects (ADP). Recipients print the report from the browser.

  • graphics/2002_icon.gif Live Web reports are similar to static XSL/XML Web reports, but deliver current data by executing an Active Server Pages (ASP) or HTML template query against SQL Server when opening the page in a browser. Live Web reports were one of the most important new features of Access 2002.

To learn more about static and live Web Reports, see "Exporting Static Reports as XML," p. 965 and "Exporting Live Web Reports," p. 967.


Some reports consist of a single page, such as an order acknowledgment, invoice, graph, or chart. Multipage Access reports typified by catalogs, general ledgers, and financial statements are more common than the single-page variety. A multipage report is analogous to a continuous form that's been optimized for printing.

Most methods of creating Access forms, which you learned about in Chapter 14, "Creating and Using Access Forms," and Chapter 15, "Designing Custom Multitable Forms," also apply to reports. The following list details the principal differences between reports and forms:

  • Reports are intended for printing only and, unlike forms, aren't designed for display in a window. When you view an 8 1/2x11-inch report in the default Print Preview, its content usually isn't legible. In the zoomed (full-page) view, only a part of the report might be visible in the Print Preview or Layout Preview window, depending on the resolution of your monitor.

  • You can't change the value of the underlying data for a report with a control object from the toolbox as you can with forms. With reports, Access disregards user input from combo boxes, option buttons, check boxes, and the like. The primary controls you use on forms are labels and text boxes. You can use a check box to indicate the value of field of the Yes/No (Boolean) data type.

  • Reports don't provide a Datasheet view. Only Print Preview, Layout Preview, and Report Design views are available. Layout Preview provides a quick view of the form without displaying all its data.

  • In multicolumn reports, the number of columns, the column width, and the column spacing are controlled by settings in the Printer Setup dialog, not by controls that you add or properties that you set in Design view.

Access reports share many characteristics of forms, including the following:

  • Report Wizards create the three basic kinds of reports: single-column, groups/totals, and mailing labels. You can modify as necessary the reports that the Report Wizard creates. The function of the Report Wizard is similar to that of the Form Wizard discussed in Chapter 14.

  • Sections include report headers and footers, which appear once at the beginning and at the end of the report, and page headers and footers, which print at the top and bottom of each page. The report footer often is used to print grand totals. Report sections correspond to similarly named form sections.

  • Group sections of reports, as a whole, comprise the equivalent of the Detail section of forms. Groups often are referred to as bands, and the process of grouping records is known as banding. You can add Group Headers that include a title for each group, and Group Footers to print group subtotals. You can place static (unbound) graphics in header and footer sections and bound graphics within group sections.

  • Controls are added to reports from the Access toolbox and then moved and sized with their handles. Reports support embedded bitmaps, OLE objects, such a graphs and charts you create with MSGraph.exe, and ActiveX controls, such as the PivotChart and PivotTable.

  • Subreports can be incorporated into reports the same way you add subform controls within main forms.



Special Edition Using Microsoft Office Access 2003
Special Edition Using Microsoft Office Access 2003
ISBN: 0789729520
EAN: 2147483647
Year: 2005
Pages: 417

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