Access closes

G

Guest

Using Windows XP Home Edition and Access 2000, Access unexpectedly closes for
no apparent reason. It has happened often, but not always, when the Save
icon on the Visual Basic window is pressed. It also sometimes happens when
various form buttons are pressed. In all cases, I definitely was not
expecting Access to close and sometimes modifications were lost. I have not
yet determined how to duplicate the problem. This has happened with the same
database file on two different PCs, both of which are networked with other
PCs but not together.

Any ideas? Thanks.
 
D

Dirk Goldgar

Thos said:
Using Windows XP Home Edition and Access 2000, Access unexpectedly
closes for no apparent reason. It has happened often, but not
always, when the Save icon on the Visual Basic window is pressed. It
also sometimes happens when various form buttons are pressed. In all
cases, I definitely was not expecting Access to close and sometimes
modifications were lost. I have not yet determined how to duplicate
the problem. This has happened with the same database file on two
different PCs, both of which are networked with other PCs but not
together.

Any ideas? Thanks.

I'd suspect that the database file itself is corrupted in some way,
probably in the VB project. Try decompiling the database and see if the
problem goes away. Here's how:

1. With the database closed -- no users in it at all -- and (ideally)
Access not running, make a backup copy.

2. On the task bar, click Start -> Run...

3. Enter this (adapted match your database path and name) in the Run
dialog box and click OK:

msaccess.exe /decompile "C:\My Documents\YourDBName.mdb"

You *may* need to include the full path to msaccess.exe, but I don't
find that to be the case when I try it. Depending on your Access
version, you may not get any sign that anything in particular happened.
Your database will probably open in Access.

4. Compact and Repair your database.

5. Open the database again, press Alt+F11 to switch to the VB Editor,
and click Debug -> Compile (your project). If any errors appear, fix
them and recompile.

6. Close the VB Editor. Compact & Repair again.

See if the problem has disappeared.

If the problem has *not* disappeared, try creating a new blank database,
then importing all objects from the old database to the new one.
 

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