Skip to Content
avatar image
Former Member

Reset manual running total on each group

Due to the fact that I can not sum a formula I am using a manual running total, I found in a previous post, and it works great to get the grand total. However, I need to somehow setup one that will reset at each new group so that I have a total on each group. Any ideas on how I could accomplish this? Does this make sense?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    avatar image
    Former Member
    Jul 10, 2009 at 01:43 PM

    In order to have a running total that resets at each group AND a grand total at the bottom, you would need essentially 5 formula fields.

    The first three are for the group totals:

    1) the running total field that has

    i :=i+{@total}

    2) a reset formula in the group header with

    i:=0

    3) a display formula for i in the group footer.

    Then another 2 formulas using a different variable

    1) the running total field (placed in the same section as your other one) with

     WhilePrintingRecords;
    Global NumberVar X;
    X :=X+{@Total}

    2) a display formula for X in the report footer.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      That is perfect! I have been trying to figure this type of issue out for a long time now. I appreciate it very much.

  • avatar image
    Former Member
    Jul 09, 2009 at 02:33 PM

    Brent,

    Place this formula in the group header:

    WhilePrintingRecords;

    Global NumberVar yourvariablename:=0;

    Please note: you will need to create another variable if you want to keep your grand total.

    I hope this helps;

    Zack

    Add comment
    10|10000 characters needed characters exceeded