Running totals keep doubling up when... (contd)
Hi,
A couple of weeks ago I asked the following question:
I have a report which displays on two pages. Due to some complexities,
the grand total report is calculated by using variables within the report.
In summary, I have a group with calc variables which has a running total of
a variable that I have defined. Timing is set to calculate on the footer
end of the group. Then the grand total simply displays this. The first
time the report is run and I go to the second page, the total is correct.
If I go back to first page and then the second again, the grand total
doubles. If I do it again, it is tripled.
I didnt realise the report gets recaclulated once it has been created. Is
there a way to stop calculations once report has run for the first time,or
any other solution?
It was kindly suggested that I set Report.CachePages to True.
This appears to work on-screen however when I print the report to a printer
the grand totals double again, which makes the printed report wrong. Any
ideas?
Cheers,
Alex Vasitch
A couple of weeks ago I asked the following question:
I have a report which displays on two pages. Due to some complexities,
the grand total report is calculated by using variables within the report.
In summary, I have a group with calc variables which has a running total of
a variable that I have defined. Timing is set to calculate on the footer
end of the group. Then the grand total simply displays this. The first
time the report is run and I go to the second page, the total is correct.
If I go back to first page and then the second again, the grand total
doubles. If I do it again, it is tripled.
I didnt realise the report gets recaclulated once it has been created. Is
there a way to stop calculations once report has run for the first time,or
any other solution?
It was kindly suggested that I set Report.CachePages to True.
This appears to work on-screen however when I print the report to a printer
the grand totals double again, which makes the printed report wrong. Any
ideas?
Cheers,
Alex Vasitch
This discussion has been closed.
Comments
If you use TppVariables to perform all calculations and set the calc
timing correctly then the doubling up should not occur.
If you would like to create a simple Delphi project that demonstrates
the issue, perhaps using the DBDemos data, you can send to
support@digital-metaphors.com in .zip format and we can check it out
here.
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com