Document.Sync Property

Word Developer Reference

Returns a Sync object that provides access to the methods and properties for documents that are part of a Document Workspace.

Syntax

expression.Sync

expression   Required. A variable that represents a Document object.

Example

The following example displays the name of the last person to modify the active document if the active document is a shared document in a Document Workspace.

Visual Basic for Applications
  Dim eStatus As MsoSyncStatusType
Dim strLastUser As String

eStatus = ActiveDocument.Sync.Status

If eStatus = msoSyncStatusLatest Then strLastUser = ActiveDocument.Sync.WorkspaceLastChangedBy MsgBox "You have the most up-to-date copy." & _ "This file was last modified by " & strLastUser End If

See Also