I have a VBA code (below) to run at a form "On Open" event, but am getting the error, "Run-time error '3211'; The database engine could not
lock table 'Items' because it is already in use by another person or process". Anyone know what I can add to my code to make sure the table instance (which is somehow being locked through the main switchboard form) is closed?
Code:
Private Sub Form_Open(Cancel As Integer)
DoCmd.Close acTable, "tblWell_ID"
DoCmd.OpenQuery "qryWell_ID"
End Sub
lock table 'Items' because it is already in use by another person or process". Anyone know what I can add to my code to make sure the table instance (which is somehow being locked through the main switchboard form) is closed?
Code:
Private Sub Form_Open(Cancel As Integer)
DoCmd.Close acTable, "tblWell_ID"
DoCmd.OpenQuery "qryWell_ID"
End Sub