Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Report Design
Message Icon Topic: Total Page Count Post Reply Post New Topic
Author Message
Jonart
Newbie
Newbie


Joined: 02 Apr 2012
Online Status: Offline
Posts: 16
Quote Jonart Replybullet Topic: Total Page Count
    Posted: 02 Mar 2013 at 7:31pm
I have a report that requires seven hours to run. I would like to shorten the runtime. When the report is running I noticed the message which appears at the bottom left corner of the screen. It seems to indicate what type of operation Crystal is doing: Reading Records, Subreport, Accessing Database, Determining Total Page Count. It is this last message that interests me, as it seems to appear each time Crystal reads and processes a record. The report should run faster if I could eliminate whatever is causing Crystal to Determine Total Page Count. I realized that some text objects in the page header contained conditional suppression formulas in the form of

If PageNumber = TotalPageCount ...

I commented out those formulas and reran the report. But it does not seem faster and the message Determining Total Page Count still flashes.

Do all reports need to determine the page count even if there are no formulas that include this function? Does this affect runtime?
IP IP Logged
Sastry
Moderator
Moderator
Avatar

Joined: 16 Jul 2012
Online Status: Offline
Posts: 537
Quote Sastry Replybullet Posted: 03 Mar 2013 at 9:42pm
HI

Check whether you have 'Page N of M' placed on the report. Also you need to check 'Total Page Count' is used in any other formulas or it was placed in the report.

Thanks,
Sastry
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3701
Quote hilfy Replybullet Posted: 04 Mar 2013 at 3:54am
If you have Page N of M or Total Page Count anywhere in the report, Crystal has to physically render every page while it's generating the report.  This can cause significant speed issues.  I recommend that you replace "If PageNumber = TotalPageCount..." with something like "If OnLastRecord..."
 
-Dell
IP IP Logged
Jonart
Newbie
Newbie


Joined: 02 Apr 2012
Online Status: Offline
Posts: 16
Quote Jonart Replybullet Posted: 04 Mar 2013 at 4:36am
Yes, my report does have Page n of m. I will remove that and try again.

Thank you Sastry and Dell
IP IP Logged
Jonart
Newbie
Newbie


Joined: 02 Apr 2012
Online Status: Offline
Posts: 16
Quote Jonart Replybullet Posted: 04 Mar 2013 at 5:35am
That simple change doubled the speed.

Thanks!
Jonart
IP IP Logged
Jonart
Newbie
Newbie


Joined: 02 Apr 2012
Online Status: Offline
Posts: 16
Quote Jonart Replybullet Posted: 04 Mar 2013 at 8:25am
Originally posted by hilfy



I recommend that you replace "If PageNumber = TotalPageCount..." with something like "If OnLastRecord..."
 
-Dell


OnLastRecord also worked perfectly for the conditional suppression.

Jonart
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.016 seconds.