tags:

views:

264

answers:

2

I have an MS Access 2002 database with password security.

When I exit the application, the password dialog box reappears. Now, after this I can only exit the application if I give in the password again or press Cancel.

I don't know why this dialog appears on exit.

A: 

Sounds like something is happening either in an exit macro or module. I don't remember what the exact events are called, but that's where I would check first.

Jeff Schumacher
+1  A: 

Is COMPACT ON CLOSE perhaps turned on? I'm not sure how it works (since I would never even consider using it), but perhaps it closes the database, compacts it and reopens it for some housekeeping? Doesn't make much sense, but you should consider COMPACT ON CLOSE, anyway, because:

  1. it is useless: any Access app should be split, and users will only ever open the front end directly. Since the front end has no data stored in it, there is no need to ever compact it (if it bloats, replace it with a new one, or redesign it properly, so that it doesn't bloat).

  2. it is dangerous: under certain circumstances, a Jet database can be in a corrupt state, but still open, with all the data still accessible. But in some small percentage of cases, a compact of a database in that state will cause some of the data that was still accessible to be lost during a compact (I've seen it happen when a PK index got corrupted). So, since you can't cancel it, you are in danger of losing data that would otherwise remain accessible without a compact.

--
David W. Fenton
David Fenton Associates

David-W-Fenton
I thought that could be the problem myself. But, it turns out that that was not the case.Anyway, I created a new database and imported all my tables/data into it and it worked like a charm.Thanks! :)
Adhip Gupta