AutoSave Crash Recovery

  • Thread starter Thread starter John Wright
  • Start date Start date
J

John Wright

I want to create an autosave and crash recovery module for my program. I
imagine I would have to use a timer control on the form to call the autosave
functionality but I need a starting point. I would like it similiar to the
functionality in word when a PC goes offline (power failure, etc) it will
ask to recover open files, I would like to have this same functionality.
Does anyone have any suggestions or point me in the right direction? Thanks.

John
 
I want to create an autosave and crash recovery module for my program. I
imagine I would have to use a timer control on the form to call the autosave
functionality but I need a starting point. I would like it similiar to the
functionality in word when a PC goes offline (power failure, etc) it will
ask to recover open files, I would like to have this same functionality.
Does anyone have any suggestions or point me in the right direction? Thanks.

John

What kind of application is this? How much "stuff" needs to be saved?
Do you have a save/open file system currently in place?

Thanks,

Seth Rowe
 
Most of the data is in textboxes on the form. Well under 100K. There is a
save in place but the user must click the save button to initiate this
action and it will post it back to the database. I want to save it locally
until they have clicked the save button then clear out the temp file for the
next record. This will not happen at a quick interval, I just need
something to help in case of power failure.
 
Most of the data is in textboxes on the form. Well under 100K. There is a
save in place but the user must click the save button to initiate this
action and it will post it back to the database. I want to save it locally
until they have clicked the save button then clear out the temp file for the
next record. This will not happen at a quick interval, I just need

Since you probably don't want to use the database as a "temp" file, my
vote would be to use an XML file to store the information. Then, say
every 5 minutes, your application would dump the information into this
Xml file, and when the user exit the application normally (ie not a
power failure) then delete the Xml file. That way you can do a quick
check for the presence of this temporary Xml file on startup and if
the file exists you prompt the user if he/she would like to load it.

I hope I made sense, as it is earlier in the morning! If I didn't, or
you would like a code sample of this, let me know!

Thanks,

Seth Rowe
 
Back
Top