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!

Summing Certain Values in a Report 1

Status
Not open for further replies.

dmlatham

Programmer
Oct 12, 2001
28
0
0
US
I am currently trying to create a report that only sums certain values. For instance (please note the totals with a * preceding),

Trial
Personal 6
Joint 4
Never Handled 8

* Personal and Joint Total 10
Trial Total 18

App Memo
Personal 5
Never Handled 6

* Personal and Joint Total 5
Trial Total 11

Cert Memo
Never Handled 6

* Personal and Joint Total 0
Trial Total 6

----

I would like to be able to sum up the "Personal and Joint Total". I have tried the following:

=IIf(([handling_desc]="Personal" And [handling_desc]="Joint"),Sum([fy1hours_both]),(IIf([handling_desc]="Personal" Or [handling_desc]="Joint",[fy1hours_both],"0")))

I only the sum of the "Personal" instead of both when there is also a "Joint". So basically if I applied the above code the the above report example, my results for "Personal and Joint Total" will be 6,5 and 0 respectively.

Any and all help is greatly appreciated.

Deborah
 
hope this helps, I only see the need for 1 iif , hope I am reading your Prob right try this expression


=IIf([handling_desc]="Personal" Or [handling_desc] = "Joint",sum([fy1hours_both]),"0")

 
Thanks Kelly for the info.

I have implemented the above code in a table for a column named PJ_FY1hours and it works fine. I just wanted to be able to do it directly on the form. If I apply the above code to a text box on the form it does not sum up the correct values. Again Thanks..

Deb
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top