Reports for WinForms | ComponentOne
Working with C1Report / Sections of a Report
In This Topic
    Sections of a Report
    In This Topic

    Every report has at least the following five sections:

    Section Description
    Detail The Detail section contains fields that are rendered once for each record in the source recordset.
    Header The Report Header section is rendered at the beginning of the report.
    Footer The Report Footer section is rendered at the end of the report.
    Page Header The Page Header section is rendered at the top of every page (except optionally for pages that contain the Report Header).
    Page Footer The Page Footer section is rendered at the bottom of every page (except optionally for pages that contain the Report Footer).

    In addition to these five sections, there are two additional sections for each group: a Group Header and a Group Footer Section. For example, a report with 3 grouping levels will have 11 sections.

    Note that sections can be made invisible, but they cannot be added or removed, except by adding or removing groups.

    The following diagram shows how each section is rendered on a typical report:

    Report Header

    The first section rendered is the Report Header. This section usually contains information that identifies the report.

    Page Header

    After the Report Header comes the Page Header. If the report has no groups, this section usually contains labels that describe the fields in the Detail Section.

    Group Headers and Group Footers

    The next sections are the Group Headers, Detail, and Group Footers. These are the sections that contain the actual report data. Group Headers and Footers often contain aggregate functions such as group totals, percentages, maximum and minimum values, and so on. Group Headers and Footers are inserted whenever the value of the expression specified by the GroupBy property changes from one record to the next.

    Detail

    The Detail section contains data for each record. It is possible to hide this section by setting its Visible property to False, and display only Group Headers and Footers. This is a good way to create summary reports.

    Page Footer

    At the bottom of each page is the Page Footer Section. This section usually contains information such as the page number, total number of pages in the report, and/or the date the report was printed.

    Report Footer

    Finally, the Report Footer section is printed before the last page footer. This section is often used to display summary information about the entire report.

    Customized sections

    You can determine whether or not a section is visible by setting its Visible property to True or False. Group Headers can be repeated at the top of every page (whether or not it is the beginning of a group) by setting their Repeat property to True. Page Headers and Footers can be removed from pages that contain the Report Header and Footer sections by setting the PageHeader and PageFooter properties on the Layout object.