drawing objects removed

G

Guest

In a speadsheet used by many people, there are some arrows put in using the
drawing toolbar. Some people have copied worksheets hundreds of times,
resulting in the arrows existing hundreds of times (on multiple sheets). The
only way I have found to delete them is to click on it and hit delete, and
then there are still hundreds of more times I need to repeat the task. Can I
delete all of these arrows at once, or at least not one at a time?

Thanks
 
D

Don Guillett

This might make your life happier. However, it will do ALL on the sheet.
Sub ShapesCut()
For Each S In ActiveSheet.Shapes
S.Cut
Next
End Sub
 
D

Debra Dalgleish

You can delete shapes that don't have the same name as your button. For
example:

Sub DeleteShapes()
Dim shp As Shape
For Each shp In ActiveSheet.Shapes
If shp.Name <> "MyButton" Then shp.Delete
Next shp
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top