Count Property

Microsoft PowerPoint Visual Basic

Count Property

       

Returns the number of objects in the specified collection.

Read-only Integer for the following objects: Adjustments, CanvasShapes, DiagramNodeChildren, DiagramNodes, GroupShapes, ShapeNodes, and Shapes.

Read-only Long for the following objects: ActionSettings, AddIns, AnimationPoints, Animations10, Borders, CellRange, ColorScheme, ColorSchemes, Columns, Comments, Designs, DocumentWindows, ExtraColors, Fonts, Hyperlinks, NamedSlideShow, NamedSlideShows, ObjectVerbs, Panes, Placeholders, Presentations, PrintRanges, PublishObjects, Rows, RulerLevels, ShapeRange, SlideRange, Slides, SlideShowWindows, TabStops, Tags, TextRange, TextStyleLevels, TextStyles, TimeNodes, and Triggers.

Example

This example closes all windows except the active window.

With Application.Windows
    For i = 2 To .Count
        .Item(2).Close
    Next
End With