We value your feedback.

Take our survey and automatically be enter to win anyone of the following:

Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

The Print When expression is used at the presentation layer of the report form but not in the calculations.

You have to design the calculated field conditionally, i.e.

if your Print When expression says e.g. "OrderYear = YEAR(DATE())" which means print just values belonging to this year then you have to add the condition to the field in Group total:

The original field: "OrderQty" (calculated as SUM in the Group footer)

The new field: "IIF(OrderYear = YEAR(DATE()), OrderQty, 000000.00)"

BUT that's not all... You've requested to ignore repeated values in the SUM.

I have to say this is not possible in the report engine and you have to generate such data with respect to your requirement, e.g. sum the values in the program before the REPORT FORM command. You'll probably need two tables connected in relation to allow correct printout.

BTW, it is not obvious to omit repeated values from the SUM. Are you 100% sure two equal values must be summed as one number in all possible situations? Imagine e.g. two different orders having exactly same order total...

Of course, if you are just counting distinct values then you have to omit all redundances. But again, it is easier to count such values in the code prior to the REPORT FORM.