Application.ActiveWindow method (Outlook)
Returns an object representing the current Microsoft Outlook window on the desktop, either an Explorer or an Inspector object.
Syntax
expression.ActiveWindow
expression A variable that represents an Application object.
Return value
An Object that represents the current Outlook window on the desktop. Returns Nothing if no Outlook explorer or inspector is open.
Example
This Microsoft Visual Basic for Applications (VBA) example minimizes the topmost Outlook window if it is an inspector window.
Sub MinimizeActiveWindow()
If TypeName(Application.ActiveWindow) = "Inspector" Then
Application.ActiveWindow.WindowState = olMinimized
End If
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.