Document.CheckIn (Word)
Returns a document from a local computer to a server, and sets the local document to read-only so that it cannot be edited locally.
To take advantage of the collaboration features built into Microsoft Word, documents must be stored on a Microsoft SharePoint Portal Server.
CheckIn (SaveChanges, Comments, MakePublic)
Sub CheckInOut(docCheckIn As String)
If Documents(docCheckIn).CanCheckin = True Then
Documents(docCheckIn).CheckIn
MsgBox docCheckIn & " has been checked in."
Else
MsgBox "This file cannot be checked in " &
"at this time. Please try again later."
End If
End Sub
Arguments
Optional arguments
The following arguments are optional
SaveChanges (Boolean) - True saves the document to the server location. The default is True.
Comments (String) - Comments for the revision of the document being checked in (only applies if SaveChanges equals True).
MakePublic (Boolean) - True allows the user to perform a publish on the document after being checked in. This submits the document for the approval process, which can eventually result in a version of the document being published to users with read-only rights to the document (only applies if SaveChanges equals True). The default is False.