Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

Inspector.CurrentItem Property

Office 2007
Returns an Object representing the current item being displayed in the inspector. Read-only.

Syntax

expression.CurrentItem

expression   A variable that represents an Inspector object.

Remarks

If no item is currently open, an error message will be returned.

Example

This Visual Basic for Applications (VBA) example uses the CurrentItem property to obtain the current item that the user is viewing and closes it. If no item is currently open, an error message will be returned.

Visual Basic for Applications
Sub CloseItem()
    Dim myItem As Object

    Set myItem = Application.ActiveInspector.CurrentItem
    myItem.Close olSave
End Sub



Community Additions

ADD
Show:
© 2015 Microsoft