# TaskPanes Property

A read-only property that returns a reference to the TaskPanes collection that is associated with the Window object.

expression.TaskPanes

expression Required. An expression that returns a reference to the Window object.

## Security Level

0: Can be accessed without restrictions.

## Remarks

The TaskPanes property can be used only with the editing window types; if used with a designing window type, it will return an error.

## Example

In the following example, the TaskPanes property of the Window object is used to set a reference to the TaskPanes collection:

    var objTaskPanes;

    objTaskPanes = Application.ActiveWindow.TaskPanes;

©2003-2004 Microsoft Corporation. All rights reserved. Permission to copy, display and distribute this document is available at: http://msdn.microsoft.com/library/en-us/odcXMLRef/html/odcXMLRefLegalNotice.asp