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

#Errors Returned in report

Status
Not open for further replies.

fbicfc

Technical User
Nov 13, 2002
35
GB
Hi,

I am in the process of re-doing someone else's reporting system which is a bit of a shambles.

The basic reports all ask for the same information when opened, this is query boxes asking for : Start Date, End Date, Section.

This all works grand if there is actually relevant data in *ALL* of the records matching the specified criteria, if not the report just displays a list of #Errors for the output, eg. Start date = 01/04/04 - End date = 01/05/04 - section - Admin, this would return all #Errors on the report because there is no data for the Date period specified.

My question is : Is it possible to trap the #Errors and display a message to the user that not all of the criteria for the report can be fulfilled?

I hope there is a way to do this because I am ripping my hair out.

TIA

FBICFC
 
Query parameters are tough to deal with. Could you run the reports through a command button on a form?? If you can, add text boxes to the form, one representing each parameter and change your query criteria to use these controls. Then, in your report header set the control source for those text boxes to their respective form text boxes.

Hoc nomen meum verum non est.
 
Hi

Thanks for the reply,

I got around the problem by creating a Public function to look for Null Values used in conjunction with the NoData Event in Access, basically stops the report from running and displays a message box informing the user that the search criteria cannot be met.

FBICFC
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top