Compacting Access DB

Results 1 to 2 of 2

Thread: Compacting Access DB

  1. #1
    Joe Rutledge Guest

    Default Compacting Access DB

    Can this be done using ASP and VBScript, and if so how????<BR><BR>Thanks guys...<BR>&#060;!-- "Too weird to live,<BR> Too rare to die." --&#062;

  2. #2
    Josh Rolfe Guest

    Default RE: Compacting Access DB

    There may be an easier way to do it, but this is how I do it. First of all, I use a component called ASPEXEC. This lets you execute commands and open applications on the server. See<BR>for more info on ASPEXEC. I use ASPEXEC to launch an access database (on the server). The database has a macro called autoexec which is used to execute a function (any macro called autoexec will run automatically when the database is opened). The function compacts the database using the DBEngine.CompactDatabase method (see the access help files on this for more info). Then I use the "quit" method to close access. You do not have to open the database you want to compact itself, you can use a different database whose sole purpose is to compact the database in question. This will speed things up if you are compacting a large database. And of course, this requires you have Access installed on your web server.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts