Shape.Delete method (PowerPoint)

Deletes the specified Shape object.

Syntax

expression.Delete

expression A variable that represents a Shape object.

Example

This example deletes all freeform shapes from slide one in the active presentation.

With Application.ActivePresentation.Slides(1).Shapes

    For intShape = .Count To 1 Step -1

        With .Item(intShape)

            If .Type = msoFreeform Then .Delete

        End With

    Next

End With

See also

Shape Object

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.