I developed a backup utility for Access applications after a long sad
tale of woe and lies, more lies and still more lies from the IT
department of a major bank. As you must be aware, regular backup
utilities don't address all of the needs of Access databases. In time
they can become corrupt. This is a function of issues internal to
Access that normal backups don't address. As time has gone on, the
Access team have added a few nifty goodies but they don't go far
enough. You can now set your application to "compact on close". You
can also set it to automatically backup. However, each backup writes
over the only other backup you have created with this process..
Better than nothing but not much gain there! Another huge problem
with those solutions is that a properly implemented Access application
is split. The Front End is all that gets backed up and/or compacted
in a split application. The Back End, with the data, doesn't benefit.
Yet its the Back End that needs it most. The least sophisticated
developers will benefit the most. They're not in multi-user
situations and they wouldn't think of splitting their application. So
it works for them, somewhat.
My utility is called each time the protected application closes. It
operates as another Access application that lists the files to backup
and the root folder for the backups. Beneath that root folder, named
Backups by default, are 7 day-of-the-week files. The Backup root for
the protected application and all of the day files are created by the
application. The Front End and Back End can have different
destinations. For example you could backup the Front End below the
application's folder and backup the Back End on a server.
A text file log is written in the application folder of every event to
do with backing up the files.
Each file is compacted into its day file destination and left
untouched in its original location with a different extension. The
compacted file is then restored back to its original location with its
original name and extension.
In multi-user applications it's unlikely that the first person to quit
the application is also the last. That means that an attempt to gain
exclusive access to the Back End will fail. The utility quietly
finishes the rest of its business and exits. Eventually the last user
will quit the application. When that user's utility tries to gain
exclusive use of the Back End it will succeed. The Back End is
properly backed up, compressed and restored and all is well.
I was within a month or so of having it up on a web site when my
daughter moved another project in front of me. When I get her test
generator done I'll wrap up the backup utility.
HTH