Need a total (zero) from a subreport with no data

Nancy26

New member
Local time
Today, 08:14
Joined
Aug 3, 2001
Messages
9
I have a report and subreport.
I have a field on the subreport to get the sub report total and a field on the report for the report total - which get added together for a grand total. The problem occurs if there is no data for the subreport - I get #ERROR in my total field for the combined subreport + report totals.
How can I make the value of my subreport total = 0 when there is no data?

Thanks,
Nancy
 
Use the HasData function on the main report.
=IIf([Orders].[Report].[HasData],[Orders].[Report]![OrderCount],0) wher Orders is the sub report and OrderCount is the control on the sub.
HTH
 

Users who are viewing this thread

Back
Top Bottom