.IDB (backup) not closing

B

Bonnie43

When I open one of my databases, there is a second application that opens
(.idb). Once I am done updating the database and close, the idb file remains
visible all the time. I cannot delete it either, states that it is being used
by another program. Will this cause any issues?
 
D

Dirk Goldgar

Bonnie43 said:
When I open one of my databases, there is a second application that opens
(.idb). Once I am done updating the database and close, the idb file
remains
visible all the time. I cannot delete it either, states that it is being
used
by another program. Will this cause any issues?


I think you'll find that that is an .ldb (LDB) file, not an .idb file. This
is the "lock" file that Access uses to manage multiple users of the database
(and it's created even if there's only one user). Access *should* delete
this file automatically when the last user exits the database. The fact
that it's not being deleted, and you can't delete it manually, suggests that
Access isn't really being terminated when you close it.

The most common cause of this is a dangling object reference. Do you have
any object variables (such as DAO Database or Recordset objects) that are
global in scope? Make sure such objects are closed (if appropriate) and set
to Nothing when you exit. Are you automating another program, such as Excel
or Word? In such cases there are mistakes you can make that create an
object reference behind the scenes, which is not closed and which can keep
Access from completely closing.
 
T

Tony Toews [MVP]

Dirk Goldgar said:
The most common cause of this is a dangling object reference. Do you have
any object variables (such as DAO Database or Recordset objects) that are
global in scope? Make sure such objects are closed (if appropriate) and set
to Nothing when you exit. Are you automating another program, such as Excel
or Word? In such cases there are mistakes you can make that create an
object reference behind the scenes, which is not closed and which can keep
Access from completely closing.

Also you will see msaccess.exe hanging about in the Task Manager when
this happens. And you can't run an Access program again as nothing
happens no matter how often you click.

Tony
--
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
Tony's Microsoft Access Blog - http://msmvps.com/blogs/access/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top