Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Running Total of Unsuppressed Records Post Reply Post New Topic
Author Message
ChrisG
Newbie
Newbie


Joined: 12 Mar 2013
Online Status: Offline
Posts: 20
Quote ChrisG Replybullet Topic: Running Total of Unsuppressed Records
     Posted: 08 May 2013 at 6:00am
Hi There,
I have a report in which I am trying to create a running total sum of a field called {@Disc.Total) but it is still returning all the suppressed/unsuppressed values. I have tried the 'Three Formula Crystal' trick but it is still returning the collective value when I am just looking for the unsuppressed values.

Help would be appreciated.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 08 May 2013 at 6:44am

I assume the 3 formula trick you are referring to is using shared variables.

formula '2' needs to use a condition in it to include or exclude each row. That condition will be the same as your suppression condition.
 
The same thing can be done in a Running Total using an evlauation formula.
IP IP Logged
ChrisG
Newbie
Newbie


Joined: 12 Mar 2013
Online Status: Offline
Posts: 20
Quote ChrisG Replybullet Posted: 08 May 2013 at 9:20pm
Hi DB,
So if my suppression formula is:
 if {QuoteDtl.ShortChar01} = "" then true

Then where would i include the 2nd variable of:
WhilePrintingRecords;
NumberVar Total;
Total:= Total + {@Disc.Total}

Where would the suppression be placed? Just a bit unsure of formula placement.

Cheers
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 10 May 2013 at 2:13am
WhilePrintingRecords;
NumberVar Total;
Total:= Total + (if {QuoteDtl.ShortChar01} = "" then 0 else {@Disc.Total})
IP IP Logged
ChrisG
Newbie
Newbie


Joined: 12 Mar 2013
Online Status: Offline
Posts: 20
Quote ChrisG Replybullet Posted: 12 May 2013 at 9:11pm
Thanks DB. Just wasn't sure about adding the if statement to a variable condition. Works a treat.

Cheers
IP IP Logged
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