Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Find difference between values in group header

Status
Not open for further replies.

itkyle

IS-IT--Management
Feb 13, 2002
31
0
0
US
I have a report in which I placed the sum of a field in a group header, which gives me the figures I want grouped by year. In the report footer, I'd like to be able to show the difference between 2 years based on that sum in the header. For instance, when I run my report I get 1 group for 2000 showing a result of 99, the next grouping for 2001 shows 97; I want to be able to reflect the difference (2) in the report footer.

Any ideas? More info needed? Let me know. Thanks!

Kyle
 
Set up a text box on the footer with the control source = me.[Total99] - me.[Total2000]. Total99 represent the name of the textbox with the total for where you have the sum for 1999. Total2000 represent the name of the textbox with the total for 2000. See it this helps
 
The problem is that both of these totals are in the same textbox - it appears in a group header, so it just repeats for each grouped year. Should the calculation be placed somewhere else?

Thanks for your help.

Kyle
 
There may be a more sophisticated way to do this, I
just placed two formulas (hidden) in the details section
that if the date was 2000 then show the amount and did a second identical one for 2001. Inserted summaries for the two then created a formula to subtract the two summaries and placed it in the report footer
Terri Mimbs
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top