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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sub report not showing if no results

Status
Not open for further replies.

blurworld

Programmer
Sep 19, 2001
46
0
0
GB
Hi

A subreport can return no results (but is then not shown at all!!!) whilst the main report does return results and is shown. Therefore when i try to calculate a total from that subreports i.e. 0, as it hasn;t returned any reults - i cannot as i cannot get that fact,,, How can i know when no results have been returned!? please help!

-Martin
 
Nope - that doesn't work! i still get #error - seems the subreports properties are not even available when the subreport contains no records - therefore i don;t see how i can determine if there are no records (easily) in the subreport - what should i do?
 
This is standard access behavior and there is no way around it. What you can do is try putting an IsError function around your function that your running that is returning the #Error and plug a value (like 0 or N/A) when the subreport doesn't exist.

=IIf(IsError(MyFunctionHere)=True,"N/A",MyFunctionHere)

HTH Joe Miller
joe.miller@flotech.net
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top