DocumentInspector object (Office)
Represents a Document Inspector module in a DocumentInspectors collection.
Remarks
The DocumentInspector object provides access to the Inspect and Fix methods.
The DocumentInspector object represents custom Document Inspector modules and some "built-in" options. To see the list of built-in options, open the Document Inspector dialog box from the File menu. The first two options (Comments, Revisions, Versions, and Annotations and Document Properties and Personal Information) are not listed in the DocumentInspectors collection; instead, their functionality is available through the RemoveDocumentInformation method.
The remaining options in the dialog box and any installed custom modules developed by third-party sources are available from the DocumentInspectors collection by specifying an index value.
Example
The following example inspects a document by using a Document Inspector module, and displays the status and results of the inspection.
Public Sub DI_InspectDocument()
Dim docStatus As MsoDocInspectorStatus
Dim result As String
ActiveDocument.DocumentInspectors(3).Inspect docStatus, results
MsgBox ("The inspection returned the following status " & docStatus & _
" with this result " & result)
End Sub
See also
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.