Skip to content

Latest commit

 

History

History
59 lines (37 loc) · 1.33 KB

PowerPoint.DocumentWindow.Active.md

File metadata and controls

59 lines (37 loc) · 1.33 KB
title keywords f1_keywords api_name ms.assetid ms.date ms.localizationpriority
DocumentWindow.Active property (PowerPoint)
vbapp10.chm511008
vbapp10.chm511008
PowerPoint.DocumentWindow.Active
bd68b587-0811-7f40-c0da-741e2305594b
02/06/2022
medium

DocumentWindow.Active property (PowerPoint)

Returns whether the specified pane or window is active. Read-only.

Syntax

expression.Active

expression A variable that represents a DocumentWindow object.

Return value

MsoTriState

Remarks

The value returned by the Active property can be one of these MsoTriState constants.

Constant Description
msoFalse The specified pane or window is inactive.
msoTrue The specified pane or window is active.

Example

This example checks to see if the presentation file "test.ppt" is in the active window. If not, it saves the name of the presentation that is currently active in the variable oldWin and activates the "test.ppt" presentation.

With Application.Presentations("test.ppt").Windows(1)

    If Not .Active Then

        Set oldWin = Application.ActiveWindow

        .Activate

    End If

End With

See also

DocumentWindow Object

[!includeSupport and feedback]