Application.WindowActivate Event (PowerPoint)

Occurs when the application window or any document window is activated.


expression. WindowActivate( _Pres_, _Wn_ )

expression A variable that represents an Application object.


Name Required/Optional Data Type Description
Pres Required Presentation The presentation displayed in the activated window.
Wn Required DocumentWindow The activated document window.


For information about using events with the Application object, seeHow to: Use Events with the Application Object.

If your Visual Studio solution includes the Microsoft.Office.Interop.PowerPoint reference, this event maps to the following types:

  • Microsoft.Office.Interop.PowerPoint.EApplication_WindowActivateEventHandler (the WindowActivate delegate.)

  • Microsoft.Office.Interop.PowerPoint.EApplication_Event.WindowActivate (the WindowActivate event.)


This example opens every activated presentation in slide sorter view.

Private Sub App_WindowActivate (ByVal Pres As Presentation, ByVal Wn As DocumentWindow) 
    Wn.ViewType = ppViewSlideSorter 
End Sub

See also

Application Object