
Signature
--Roger Carlson
MS Access MVP
Access Database Samples: www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/wa.exe?SUBED1=ACCESS-L
On Dec 19, 4:35 pm, "Roger Carlson" <RogerCarl...@noemail.noemail>
wrote:
> On my website (www.rogersaccesslibrary.com), is a small Access database
> sample called "CompactBackEndDB.mdb" which illustrates how to do this.
[quoted text clipped - 25 lines]
>
> - Show quoted text -
Hi
I have borrowed code from your database. However, whenever I try to
run the Compact, I get an error:
3356 You attempted to open a database that is already opened
exclusively by user 'Admin' on machine 'CIOS05'. Try again when the
database is available.
It works OK in your database. What am I doing wrong?
Stapes
Roger Carlson - 19 Dec 2007 17:46 GMT
You will get the same error in my sample if you open the linked table and
leave it open while you compact it. You can't have any of the tables open
or any forms or queries open that are based on any tables in the back end
database.

Signature
--Roger Carlson
MS Access MVP
Access Database Samples: www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/wa.exe?SUBED1=ACCESS-L
> On Dec 19, 4:35 pm, "Roger Carlson" <RogerCarl...@noemail.noemail>
> wrote:
[quoted text clipped - 40 lines]
>
> Stapes
Stapes - 20 Dec 2007 09:32 GMT
On Dec 19, 5:46 pm, "Roger Carlson" <RogerCarl...@noemail.noemail>
wrote:
> You will get the same error in my sample if you open the linked table and
> leave it open while you compact it. You can't have any of the tables open
[quoted text clipped - 59 lines]
>
> - Show quoted text -
Is there any way I can query which forms are open and then close them?
I think this is my problem. And will the code still execute even if
the form which has called it been closed?
Ideally, I would want it to re-open again and report that the Compact
and Repair was successful.
Stapes