Protect Property

Microsoft Word Visual Basic

Show All

Protect Property

       

Returns or sets the protection type for the document associated with the specified routing slip. Read/write WdProtectionType.

WdProtectionType can be one of these WdProtectionType constants.
wdAllowOnlyComments
wdAllowOnlyFormFields
wdAllowOnlyRevisions
wdNoProtection

expression.Protect

expression   Required. An expression that returns a RoutingSlip object.

Example

This example protects the active document (only allows comments) and then routes it.

ActiveDocument.HasRoutingSlip = True
With ActiveDocument.RoutingSlip
    .Subject = "Status Doc"
    .Protect = wdAllowOnlyComments
    .AddRecipient Recipient:="Kim Johnson"
End With
ActiveDocument.Route