AutoSave

  • Thread starter Thread starter dgodfrey
  • Start date Start date
D

dgodfrey

Hello,

I am aware that Access saves information on a form when you close the from,
which is good. How do I code my database so that it autosaves at set time
intervals like Word does? We do not want an idle user timeout or say, power
failure/system lockup to lose data entered...we want to be able to load it
back up and resume where we left off.

Thanks.
 
If your database is split and the back end database is on an network server,
you don't have to worry about it. It is automatically saved using the
Refresh Interval setting in Tools, Options, Advanced tab. The default is 60
seconds.
 
dgodfrey said:
I am aware that Access saves information on a form when you close the from,
which is good. How do I code my database so that it autosaves at set time
intervals like Word does? We do not want an idle user timeout or say, power
failure/system lockup to lose data entered...we want to be able to load it
back up and resume where we left off.


You will need to use the form's Timer event to do something
at fixed intervals. This line can do the save:
If Me.Dirty Then Me.Dirty = False

***BUT*** you will also need to analyze all potential
scenarios where this can occur. E.g. what if a user is in
the middle of entering a value and the timer triggers a
save?

Tou will have to go to great pains to deal with any
validation rules or referential integrity restrictions that
might be violated by an incomplete field or record.

There are probably more complications in this than can
reasonably be coded around and I think pursuing this idea
will only dig yourself into a deep, deep hole.
 
I believe that is how it is going to be done in the, so this makes me feel
better.

Thanks.
 
Back
Top