Tables not able to be locked

BrettM

just a pert, "ex" to come
Local time
Today, 19:46
Joined
Apr 30, 2008
Messages
134
I have a little backup utility that works perfectly if run all by itself however when called from within the main program it errors during the restore proceedure.

At that time it is trying to delete the existing tables and that is where the error occurs.

error 3211. The database engine could not lock table... it is in use etc.

I am attempting to close the table first - obviously without success.

DoCmd.Close acTable, "tblHours"
DoCmd.DeleteObject acTable, "tblHours"

tblHours is the main table opened by the database. Obviously I am missing something here so I am hoping someone can give me some guidance.

Regards Brett
 
Is there a form open that is bound to that table?
 
Thanks Paul,

Minor brain fart but all is well again.

Forgot all about that. Now I close the calling form, run the restore and reopen the calling form.

Good to get a nudge in the right direction.

Regards Brett
 

Users who are viewing this thread

Back
Top Bottom