View Single Post
 
Old 12-01-2020, 08:07 PM
Cendrinne's Avatar
Cendrinne Cendrinne is offline Windows 10 Office 2019
Competent Performer
 
Join Date: Aug 2019
Location: Montreal Quebec Canada
Posts: 200
Cendrinne is on a distinguished road
Default Help with Shape Deletion on Selection only

Hello Pros,
I need your help again.

Been trying to rack my brain and been trying over and over again, to Delete Shapes from a document, BUT only upon Selection. NOT from the whole document.

Code:
Sub Graph_TEST_LINES_FORME_Supp_On_Select()

ActiveDocument.Select
 For i = ActiveDocument.Shapes.Count To 1 Step -1
    
    ActiveDocument.Shapes(i).Delete
 Next i

End Sub
Is there a way?

Thanks for any insights you may provide

Cendrinne

Last edited by Cendrinne; 12-01-2020 at 10:35 PM.
Reply With Quote