Page count slows report dramatically

G

Guest

I was troubleshooting a slow-opening report today and found that when I
removed the standard (wizard-generated) page count at the bottom of my
report, the report went from 22 seconds to about 5 seconds to open.

Page footer page-count text box has this ControlSource ="Page " & [Page] & "
of " & [Pages]

Why is this? Does Access not calculate the number of pages without this
reference being on the report? Is there an alternative?
 
B

Brendan Reynolds

Access has to format the report twice when you use Pages - once to figure
out how many pages there are going to be, the second time to go back and put
that number into the expression.

I'm not aware of an alternative, if you really need the number of pages.
(It can be quite valuable, as without it someone could potentially draw the
wrong conclusion from a report because it may not be obvious that pages are
missing.)
 
F

fredg

I was troubleshooting a slow-opening report today and found that when I
removed the standard (wizard-generated) page count at the bottom of my
report, the report went from 22 seconds to about 5 seconds to open.

Page footer page-count text box has this ControlSource ="Page " & [Page] & "
of " & [Pages]

Why is this? Does Access not calculate the number of pages without this
reference being on the report? Is there an alternative?

It's not the [Page] that is slowing the report it's the [Pages].
In order to determine how many total Pages there are in the report,
Access must format the report twice. Once to get the count of the
total number of pages, then a second time to actually print or display
the report.
 
G

Guest

Yeah, I discovered that by taking out the entry piece-by-piece. It makes
sense, though, so I can't really complain.

fredg said:
I was troubleshooting a slow-opening report today and found that when I
removed the standard (wizard-generated) page count at the bottom of my
report, the report went from 22 seconds to about 5 seconds to open.

Page footer page-count text box has this ControlSource ="Page " & [Page] & "
of " & [Pages]

Why is this? Does Access not calculate the number of pages without this
reference being on the report? Is there an alternative?

It's not the [Page] that is slowing the report it's the [Pages].
In order to determine how many total Pages there are in the report,
Access must format the report twice. Once to get the count of the
total number of pages, then a second time to actually print or display
the report.
 
G

G2

Has anyone else found a solution to this problem since this was originally
posted?

G2

Brendan Reynolds said:
Access has to format the report twice when you use Pages - once to figure
out how many pages there are going to be, the second time to go back and put
that number into the expression.

I'm not aware of an alternative, if you really need the number of pages.
(It can be quite valuable, as without it someone could potentially draw the
wrong conclusion from a report because it may not be obvious that pages are
missing.)

--
Brendan Reynolds

Brian said:
I was troubleshooting a slow-opening report today and found that when I
removed the standard (wizard-generated) page count at the bottom of my
report, the report went from 22 seconds to about 5 seconds to open.

Page footer page-count text box has this ControlSource ="Page " & [Page] &
"
of " & [Pages]

Why is this? Does Access not calculate the number of pages without this
reference being on the report? Is there an alternative?
 
D

Douglas J. Steele

Brendan was being coy. If Brendan's unaware of an alternative, odds are
there isn't one.

--
Doug Steele, Microsoft Access MVP

(no private e-mails, please)


G2 said:
Has anyone else found a solution to this problem since this was originally
posted?

G2

Brendan Reynolds said:
Access has to format the report twice when you use Pages - once to figure
out how many pages there are going to be, the second time to go back and
put
that number into the expression.

I'm not aware of an alternative, if you really need the number of pages.
(It can be quite valuable, as without it someone could potentially draw
the
wrong conclusion from a report because it may not be obvious that pages
are
missing.)

--
Brendan Reynolds

Brian said:
I was troubleshooting a slow-opening report today and found that when I
removed the standard (wizard-generated) page count at the bottom of my
report, the report went from 22 seconds to about 5 seconds to open.

Page footer page-count text box has this ControlSource ="Page " &
[Page] &
"
of " & [Pages]

Why is this? Does Access not calculate the number of pages without this
reference being on the report? Is there an alternative?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top