UserControl Property

Applies To

Application object, Document object.

Description

True if the document or application was created or opened by the user. False if the document or application was created or opened programmatically with the Open method or the CreateObject or GetObject method. Read/write Boolean for the Document object; read-only Boolean for the Application object.

Remarks

If Word is visible to the user, this property will always return True.

Example

This example displays the status of the UserControl property for the active document.

If ActiveDocument.UserControl = True Then
    MsgBox "This document was created or opened by the user."
Else
    MsgBox "This document was created programmatically."
End If