Reports display data in a meaningful fashion, unless there's no data to report. When this happens, you'll want to usurp the reporting process a bit to avoid confusion. That's accomplished easily enough using the report's No Data event. Simply open the report's module and enter the following event procedure:
Private Sub Report_NoData(Cancel As Integer)
MsgBox "There's no data to report.", vbOKOnly, "Error"
Cancel = True
End SubBe sure to save the form after adding the code. When users open the report with no data to report, Access will display a meaningful message. (You can use whatever message you like, of course.) Users don't accidentally print useless reports or call you in a panic wanting to know what's wrong with the report.
Related Topics:Microsoft Enterprise Software Software Collaboration Mobility Cloud Hardware
Susan Sales Harkins is an IT consultant, specializing in desktop solutions. Previously, she was editor in chief for The Cobb Group, the world's largest publisher of technical journals.