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

No_Data event

Status
Not open for further replies.

benniesanders

Programmer
Jan 20, 2002
199
US
Hi there,

If I have something like this in the No Data event of a report, how can I keep it from giving an error? If I remove the cancen=true statement, it opens a blank report. If I leave it in, I get an error. Or are there any other ways to let the user know there is no data in a report?
Thanks.

Private Sub Report_NoData(Cancel As Integer)
MsgBox "The report has no data.", vbOKOnly + vbInformation
Cancel = True
End Sub
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top