Created
August 2, 2018 12:19
-
-
Save ateneva/21656757f25b7b48f5f8a718683e6e6e to your computer and use it in GitHub Desktop.
How do I remove certain shape types from a slide with VBA?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sub Delete_shape_type() | |
Dim p As Presentation | |
Set p = ActivePresentation | |
Dim PPS As Slide | |
Dim Sh As Shape | |
'*************************** | |
For Each PPS In p.Slides | |
For Each Sh In PPS.Shapes | |
If Sh.Type = msoPicture Then Sh.Delete | |
If Sh.Type = msoTextBox Then Sh.Delete | |
If Sh.Type = msoAutoShape Then Sh.Delete | |
Next Sh | |
Next PPS | |
End Sub |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment