Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Table locked when not being accessed

Status
Not open for further replies.

nkrst1

Programmer
Feb 13, 2001
49
0
0
US
I set up some code to append a field to a table in a different .mdb file (opened up a new workspace, etc.). It worked the first few times, but now, after a corrupt compact/repair of the other file that has the table, I'm no longer allowed to do this from the file with the code. It keeps saying that someone else (or another process) is trying to access the file, when that's clearly untrue. I can change any other table in that database the one I need.

I've compacted/repaired both databases. My db keeps thinking that some other process is trying to access the table, no matter how many different copies of the back end (with the table) I try to open and change. I've isolated to problem to being on the Front End, but that's as far as I could go... any suggestions? Is there some sort of record locking buffer I can flush or something?

Thanks in advance,

-n-
 
Hi,

I'm not sure whether this is correct or not, but I seem to remember something about an erroneous .ldb file causing this (the .ldb contains locking info).

Shut both db's down, look in the directory of both db's - if an .ldb file (with same name as one of your db's) still exists, then delete it.

Before you do this, have a look for LDB Viewer download on the net - this'll tell you who has locked the db initially (probably because of closing incorrectly).

Regards

Darrylle "Never argue with an idiot, he'll bring you down to his level - then beat you with experience." darrylles@totalise.co.uk
 
Thanks. I did look for the .ldb files earlier, but to no avail.

I eventually figured it out. I was running the code to update the table in the On_Open section of a form which was being called by the switchboard. Even though the On_Open event closed the switchboard, Access still thought it was open (which accessed the table I needed), so I go the error. I moved the code into a forms module and now it works just fine.

Thanks for you help.

-n-
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top