benniesanders
Programmer
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
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