Can anyone help? When I open some reports (Access 2003 SP 2 - File Access 2000 ADP format) I get an error "The expression On Open you entered as the event property setting produced the following error. *The expression may not result in the name of a macro, the name of a user defined function, or [Event Procedure] *There may have been an error evaluating the function, event or macro"
The code on the report is as follows..
Private Sub Report_Close()
DoCmd.Restore
End Sub
Private Sub Report_NoData(Cancel As Integer)
MsgBox "There is no data for the criteria you have selected. Please try a different criteria.", vbCritical, "Sorry"
Cancel = True
End Sub
Private Sub Report_Open(Cancel As Integer)
DoCmd.Maximize
Me.lbl_header.Caption = Form_frm_criteria_inventory.txt_header
End Sub
I have multiple reports with the same code that work, but I can't figure out why it the same reports that cause this error. I have tried to comment out all of the code on the Open event, and it still produces the same error.
Thank you for anyone that can help,
sabloomer
The code on the report is as follows..
Private Sub Report_Close()
DoCmd.Restore
End Sub
Private Sub Report_NoData(Cancel As Integer)
MsgBox "There is no data for the criteria you have selected. Please try a different criteria.", vbCritical, "Sorry"
Cancel = True
End Sub
Private Sub Report_Open(Cancel As Integer)
DoCmd.Maximize
Me.lbl_header.Caption = Form_frm_criteria_inventory.txt_header
End Sub
I have multiple reports with the same code that work, but I can't figure out why it the same reports that cause this error. I have tried to comment out all of the code on the Open event, and it still produces the same error.
Thank you for anyone that can help,
sabloomer