Hi,
This is my first question so hopefully I provide everyone with enough info. I have a database developed in Access 2000. It works fine when the users have Access 2000 or 2003 on their computer. But the couple of users that have 2007, when the 'on no data' event is executed, Access closes. Here is the code:
Private Sub Report_NoData(Cancel As Integer)
MsgBox "There are no transactions for this date.", vbInformation, "No Transactions"
Cancel = True
End Sub
It seems that it does not like the line 'Cancel = True', because when I take it out, I still get the message.
I get the messages "Access has stopped working" and then "Access is restarting". Is there a reference I need to add in 2007 in order for it to work?
Any help is greatly appreciated.
Thanks.
Start Free Trial