AutoRecover property

Microsoft Visio Developer Reference

AutoRecover property

       

Determines whether an open document with unsaved changes is copied when automatic recovery is enabled.

Version added

2000 SR-1

Syntax

boolRet = object.AutoRecover
object.AutoRecover = boolValue

boolRet

Boolean. True if automatic recovery is enabled, False if it is disabled.

object

Required. An expression that returns a Document object.

boolValue

Required Boolean. True to enable automatic recovery; False to disable automatic recovery.

Remarks

If automatic recovery is enabled (the AutoRecoverInterval property is greater than 0), all documents that are open and have unsaved changes are copied into temporary files. If you do not want a document to be recovered, set its AutoRecover property to False. The AutoRecover property is not saved with a document and must be set each time the document opens.

When Visio launches after an abnormal termination and determines that automatic recovery was enabled, it attempts to open all files that were open at termination.

  • If there is a recovery file that is more recent than the last saved copy of the file, it opens the recovered file and displays the name "<file name> (Recovered)" in the document title bar.
  • If there is no recovery file, Visio opens the last saved copy of the document.

You must still save changes to recovered documents before Visio closes. If recovered documents are not saved, changes will be deleted as in any unsaved document.