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

Error Message with parameter query 1

Status
Not open for further replies.

jazminecat

Programmer
Jun 2, 2003
289
US
I have the following parameter query that asks the user for a date, and then loads a report based on that information.

Code:
SELECT tblNextStepMainCopy.ID, tblNextStepMainCopy.[Emp#], tblNextStepMainCopy.NAME, tblNextStepMainCopy.LastStepDate, tblNextStepMainCopy.Nextstepdate, tblNextStepMainCopy.FTE, tblNextStepMainCopy.Range, tblNextStepMainCopy.Step, tblNextStepMainCopy.[Montly Sal], tblNextStepMainCopy.[Hourly rate], tblNextStepMainCopy.[Hourly/salary], tblNextStepMainCopy.[range (less than FT)], tblNextStepMainCopy.[Step (less than FT)], tblNextStepMainCopy.Department, tblNextStepMainCopy.[Position Title], tblNextStepMainCopy.[Area of Assignment], tblNextStepMainCopy.[Union Group]
FROM tblNextStepMainCopy
WHERE (((tblNextStepMainCopy.LastStepDate)>=[Last step date on or after:] Or (tblNextStepMainCopy.LastStepDate) Is Null));
I built this in the query design window.
When the user enters a date that returns zero records, I need to not load the report, and give the user a dialog box telling them there are no records that match that criteria.

any suggestions?
 
Why not playing with the NoData event of the Report ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top