Working with Access 2010 on an XP system on Citrix, I receive the diagnostic in the title when I want to open a Form or when I switch to Design View. The error is prefixed with The expressio On Click you entered as the event property setting produced the
following error. Clicking on OK cause the view of the same form.
Calling VBA code is
Private Sub btnEdit_Click()
On Error GoTo Err_btnEdit_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "frmPerson"
stLinkCriteria = "[PersonID]=" & Me![PersonID]
DoCmd.OpenForm stDocName, , , stLinkCriteria
I just note that when I open the VBA editor, the error does not occurr and the new form is opened. Even after closing the VBA editor, the error has disappeared.
Also, the problem does not occurr on my Laptop with Windows 7 and Access 2010