Applies To
Window Object.
Description
Accessor. Returns a Pane object that represents the active pane in the window. Read-only.
Remarks
This property can be used only on worksheets and macro sheets.
This property returns a Pane object. You must use the Index property to obtain the index of the active pane.
See Also
ActiveWindow Property.
Example
This example activates the next pane for the active window in BOOK1.XLS. You cannot activate the next pane if the panes are frozen. The example must be run from a workbook other than BOOK1.XLS. Before running the example, make sure that BOOK1.XLS has either two or four panes in the active worksheet.
Workbooks("BOOK1.XLS").Activate If not ActiveWindow.FreezePanes Then With ActiveWindow i = .ActivePane.Index If i = .Panes.Count Then .Panes(1).Activate Else .Panes(i+1).Activate End If End With End If