Share via


Count Property

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Returns the number of Web Parts on the current Web Part Page.

objParts.Count

Parameters

Parameter

Description

objParts  

A reference to a Parts Collection.

Remarks

The Web Part Page Header part is included in this count if it is present on the page.

The Count property applies to the Parts Collection only; use the Count method to get the number of properties in a Properties Collection.

Example 1: Microsoft Visual Basic Scripting Edition

Code

intPartsCountCount = WPSC.WebPartPage.Parts.Count

Example 2: Microsoft JScript

Code

var intPartsCountCount = WPSC.WebPartPage.Parts.Count;

Requirements

Applies to: Parts Collection

See Also

Reference

Count Method

Properties Collection

Other Resources

Web Part Page Services Component (WPSC) Object Model