V
Valeria
Dear experts,
I was trying to write a macro to select all shapes in an active sheet except
2 macro buttons.
I have been looking on the treads and used the below code. It works, only
after I have run it the list that I had in one of the cells on my sheet
(data-->validation-->list) is not showing any longer!
Can you please help me? I am using Excel 2003.
Many thanks in advance,
Best regards
Valeria
Dim Shp As Object
Dim InitialShape As Boolean
InitialShape = True
For Each Shp In ActiveSheet.Shapes
If Shp.Name = "Button 259" Then
'skip it
ElseIf Shp.Name = "Button 254" Then
'skip it
Else
Shp.Select Replace:=InitialShape
InitialShape = False
Shp.Delete
End If
Next Shp
I was trying to write a macro to select all shapes in an active sheet except
2 macro buttons.
I have been looking on the treads and used the below code. It works, only
after I have run it the list that I had in one of the cells on my sheet
(data-->validation-->list) is not showing any longer!
Can you please help me? I am using Excel 2003.
Many thanks in advance,
Best regards
Valeria
Dim Shp As Object
Dim InitialShape As Boolean
InitialShape = True
For Each Shp In ActiveSheet.Shapes
If Shp.Name = "Button 259" Then
'skip it
ElseIf Shp.Name = "Button 254" Then
'skip it
Else
Shp.Select Replace:=InitialShape
InitialShape = False
Shp.Delete
End If
Next Shp