>I tried to use the CompactDatabase command to free database
>bytes after records deletetion as follow:
>
> DBEngine.CompactDatabase "tt1.mdb", "tt2.mdb", dblangGeneral,
> dbVersion40, ";pwd=pass"
>
>But it has to specify different name for the Source and Destination.
>Can I use back the same name of the database after Compacting?
>As I would like to perform this function everytime I start my
>application (to make it transparent to the users). Any better advise?
Use the Kill statements to delete tt1.mdb and then use the Rename statement.
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com