Home End User
New Blog Posts: Merging Reports - Part 1 and Part 2

Totals change when scrolling through pages??

edited December 2002 in End User
Hi

I have some code which adds to running totals within the detail after print
event (also tried after generate). The running totals are then printed
using a variable with a calcultion to assign the running total.

As I scroll through pages these totals continually change. Obviously
totalling shouldn't be done in this way, so how can I best perform running
totals without this problem occurring. I need to total myslf as the
calculation is dependent on various field values.

Regards

Alex

Comments

  • edited December 2002
    Its OK, I've worked out the setting cached pages appears to do the trick.
    Is there any reason you would not want to use cached pages?

    Cheers

    Alex

  • edited December 2002
    You need to use TppVariable.OnCalc events and not any other event for
    calculations. The band events you are using will fire more than once as
    pages generate, especially if the bands are dynamic height and if there is
    any KeepTogether action.


    Cheers,

    Jim Bennett
    Digital Metaphors

  • edited December 2002
    Hi Alex,


    cached pages costs memory and resources, executing reports with many pages may be problematic in Win9x.

    regards,
    Chris Ueberall;
This discussion has been closed.