I want to delete only images on a slide with VBA in PowerPoint.
With the given code all shapes on the slide are being deleted.
Sub DeleteAllPictures()
ActivePresentation.Slides(1).Shapes.Range.Delete
End Sub
The Images are added with the following Code:
Sub InsertPic_EAP()
'Insert Picture
ActivePresentation.Slides(1).Shapes.AddPicture FileName:="U:\Automatisierung\3D_Module\EAP.png", _
LinkToFile:=msoTrue, _
SaveWithDocument:=msoTrue, Left:=260, Top:=110, _
Width:=270, Height:=250
ActivePresentation.Slides(1).Shapes.AddPicture FileName:="U:\Automatisierung\Bilder_AP\EAP_01.png", _
LinkToFile:=msoTrue, _
SaveWithDocument:=msoTrue, Left:=620, Top:=220, _
Width:=270, Height:=115
End Sub
How do I modify the code to only select and delete the Images on the slide.