A read-only property that returns a count of the number of TaskPane objects contained in the TaskPanes collection.
expression.Count
expression Required. Returns a reference to the TaskPanes collection.
Security Level
0: Can be accessed without restrictions.
Remarks
The Count property returns a long integer value.
Example
In the following example, the Count property is used within a Microsoft JScript for loop to iterate through the collection of TaskPane objects. It checks the Visible property of each TaskPane object and if it is True, sets it to False.
var objTaskPanes;
objTaskPanes = XDocument.View.Window.TaskPanes;
for (i=0; i < objTaskPanes.Count; i++)
{
if (objTaskPanes(i).Visible = true)
objTaskPanes(i).Visible = false;
}