My Totals is not calculating my subtotals

L

Lisa

I have a report that calculates medical equipment. If 50 or more pieces are
ordered, there is a discount price. The report subtotals all the equipment
pieces and then is supposed to return a grand total for me at the end. All
the subtotals are working fine but the total line returns zero to me. Here is
what I have in the total properties control source: =IIf(Sum([Actual Qty
Ordered])>50,[DiscountPrice]*Sum([Actual Qty Ordered]),[Price]*Sum([Actual
Qty Ordered])).

What needs to change in order for the total to work?
 
D

Duane Hookom

I would try:
=IIf(Sum([Actual Qty Ordered])>50,Sum([DiscountPrice]*[Actual Qty
Ordered]),Sum([Price]*[Actual Qty Ordered]))
 
D

Duane Hookom

I assumed [Actual Qty Ordered], [DiscountPrice], and [Price] are fields in
your report's record source. Also, if the report asks for "quantity", then I
have no idea where that is coming from.

--
Duane Hookom
MS Access MVP


Lisa said:
Hi Duane, thanks for the response. I tried that and it didn't work. It
prompted me to put in the quantity when I launched th report and returned
zero still. I must have something wrong with the query that the report is
coming from. Any other ideas?

Duane Hookom said:
I would try:
=IIf(Sum([Actual Qty Ordered])>50,Sum([DiscountPrice]*[Actual Qty
Ordered]),Sum([Price]*[Actual Qty Ordered]))


--
Duane Hookom
MS Access MVP
--

Lisa said:
I have a report that calculates medical equipment. If 50 or more
pieces
are
ordered, there is a discount price. The report subtotals all the equipment
pieces and then is supposed to return a grand total for me at the end. All
the subtotals are working fine but the total line returns zero to me.
Here
is
what I have in the total properties control source: =IIf(Sum([Actual Qty
Ordered])>50,[DiscountPrice]*Sum([Actual Qty Ordered]),[Price]*Sum([Actual
Qty Ordered])).

What needs to change in order for the total to work?
 
Top