|
 |
access thread: Report Headers And Footers
Message #1 by "Wayne Ryan" <wayne.ryan@t...> on Wed, 22 May 2002 19:32:35
|
|
Given a simple report containing people's names and their
test score (0-100). Is it possible to have the page header
show the highest score on the page and the page footer
show the lowest score on the page.
I have tried (I think) all of the various report events,
but I can't produce the desired result.
Thanks.
Message #2 by "Wayne Ryan" <wayne.ryan@t...> on Thu, 23 May 2002 19:12:49
|
|
> Given a simple report containing people's names and their
t> est score (0-100). Is it possible to have the page header
s> how the highest score on the page and the page footer
s> how the lowest score on the page.
> I have tried (I think) all of the various report events,
b> ut I can't produce the desired result.
> Thanks.
Message #3 by "Wesley Kendrick" <wez.k@n...> on Thu, 23 May 2002 19:39:40 +0100
|
|
Hi Wayne, I think you need to add an unbound field to the page header and
another to the page footer, then write some VB code to add up the scores and
print the results in the fields. You can trigger the code by the reports
'on format' property.
Hope this helps, regards, Wesley Kendrick
----- Original Message -----
From: "Wayne Ryan" <wayne.ryan@t...>
To: "Access" <access@p...>
Sent: Wednesday, May 22, 2002 7:32 PM
Subject: [access] Report Headers And Footers
> Given a simple report containing people's names and their
> test score (0-100). Is it possible to have the page header
> show the highest score on the page and the page footer
> show the lowest score on the page.
>
> I have tried (I think) all of the various report events,
> but I can't produce the desired result.
>
> Thanks.
>
Message #4 by "Wayne Ryan" <wayne.ryan@t...> on Thu, 23 May 2002 20:05:59
|
|
Thanks for the response Wesley.
I have added unbound controls to the Page Header and Page Footer.
I have also declared variables to collect the desired values for
them.
If I use the "OnFormat" event, the problem is that the Report
Writer traverses into records that will not appear on the printed
page and gives wrong results. The real application has variable
length (lines) of text, so I don't know how many detail records
will be printed. Otherwise I could just ignore the last few.
If I use the "OnPrint" event, the header appears to have been
printed already.
With my code and controls, if I move everything to the footer it
is perfect, but I can not have it that way. In the actual application
the controls must be in the Header and Footer.
|
|
 |