ACC2000: Displaying First and Last Record Per Page in Page FooterID: Q208412
|
This article demonstrates how you can create a report that displays the first and last record on a report page in the page footer for that page. This is useful if you want to create a phone book-like index on each page of a report.
This article demonstrates how you can create a report that displays the first and last record on a report page in the page footer for that page. This is useful if you are trying to create a phone book-like index on each page of a report.
The following steps will create two fields in the page footer that will
display the first record and last record on the current page. A third,
invisible, field placed in the page header will actually retrieve the
value of the first record. This value is then transferred to one of the
fields in the page footer using a SetValue macro. This method is meant to
duplicate the index that is normally seen at the bottom of a phone book
page.
To create a report that displays an index of the first and last record on a page in the page footer, follow these steps:
Macro Name Action
----------------------
SetFirstRec SetValue
SetFirstRec Actions
--------------------------------------------------
SetValue
Item: [Reports]![Index Report]![FirstRec]
Expression: [Reports]![Index Report]![IdxFirstRec]
CompanyName
ContactName
City
Region
Country
Text box:
Name: IdxFirstRec
ControlSource: [CompanyName]
Visible: No
Text box:
Name: FirstRec
Text box:
Name: LastRec
ControlSource: [CompanyName]
For more information about multi-column reports, click Microsoft Access Help on the
Help menu, type "Create a multiple-column report" in the Office Assistant or the Answer Wizard,
and then click Search to view the topic.
Additional query words:
Keywords : kbusage FmrHowto
Version : WINDOWS:2000
Platform : WINDOWS
Issue type : kbhowto
Last Reviewed: May 13, 1999