ActiveWindow Property

Applies To

Application object, Document object, Global object.

Description

Returns a Window object that represents the active window (the window with the focus). If there are no windows open, an error occurs. Read-only.

See Also

Active property, ActiveDocument property, ActivePane property, Caption property, Window object.

Example

This example displays the caption text for the active window.

MsgBox ActiveWindow.Caption
This example opens a new window for the active window and then tiles all the windows.

Set myWindow = ActiveWindow.NewWindow
Windows.Arrange ArrangeStyle:=wdTiled
This example splits the first document window.

Documents(1).ActiveWindow.Split= True