Solved

Running Total Problem

Posted on 2008-10-28
5
330 Views
Last Modified: 2011-10-19
I have a report where I am using the following formulas to create a subtotal but I am running into a problem with it creating a running total instead of a total per group.  Can you please provide me with a solution? I have attached a screenshot of what is happening.  

The Subtotal Header formula I am using is as follows:

shared numberVar DeptInformationCount;
DeptInformationCount := 0;


and the Subtotal Footer formula I am using is:

shared numberVar DeptInformationCount;
DeptInformationCount

Thank you for your help with this.

Running-Total-problem.bmp
0
Comment
Question by:SAW56
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 

Author Comment

by:SAW56
ID: 22819943
Not sure if you need this information but this is the formula I used to originally gather the detailed information data:

shared numberVar InformationCount;
shared numberVar DeptInformationCount;
if {PROBSUMMARYM1.CATEGORY} = "information" then
(InformationCount := InformationCount + 1;
    DeptInformationCount:= DeptInformationCount+ 1;
    True;)
Else
    False;
0
 
LVL 77

Expert Comment

by:peter57r
ID: 22819963
Add a first line of:

WhilePrintingRecords;

to both formulas.

(I assume by 'subtotal header' you mean 'Group Header')
0
 

Author Comment

by:SAW56
ID: 22829397
For some reason it is not working.  It is still showing a running total.
0
 
LVL 77

Expert Comment

by:peter57r
ID: 22829934
I need more info about the report structure.  There must be (at least) two grouping levels so I need to see where everything is happening.
Can you post a sample report if possible or else post a bitmap of the design view.
0
 
LVL 100

Accepted Solution

by:
mlmcc earned 500 total points
ID: 22837952
Agree.  We need to know where each formula is.

The WhilePrintingRecords; isn't needed because shared variables are only processed in the printing pass.

You need a formula to reset InformationCount to 0.

It should be in the other group header.

mlmcc
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question