Document.AutoSaveOn property (Word)

True if the edits in the document are automatically saved. Read/write Boolean.

Syntax

expression.AutoSaveOn

expression A variable that represents a Document object.

Remarks

When a new document is created, the default value for the AutoSaveOn property is False, the property is disabled, and the user's changes will need to be saved manually. However, if the document is hosted on the cloud (that is, OneDrive, OneDrive for Business, or SharePoint Online), then the AutoSaveOn property defaults to True and the edits in the specified document are automatically saved. If a cloud-hosted document is shared with other users, then their changes will also be automatically merged into the user's local copy when AutoSaveOn is True.

Table 1 AutoSaveOn behavior

AutoSaveOn Toggle State Set AutoSaveOn to True Set AutoSaveOn to False
AutoSaveOn == True No-op AutoSaveOn turned off
AutoSaveOn == False AutoSaveOn turned on No-op
Disabled Error Error

Example

This example notifies you whether the document is set to be automatically saved or not.

Sub UseAutoSaveOn()
    MsgBox "This document is being saved automatically: " & ActiveDocument.AutoSaveOn
End Sub

See also

AutoSave

Document Object

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.