View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
OssieMac OssieMac is offline
external usenet poster
 
Posts: 2,510
Default XL2003 Select each shape sequentially, show handles, and make visi

Hello Keith,

I was looking into this problem and I now see that Dave has posted a good
answer. However, you might find the following modification to Dave's code
helpful because it will make visible those shapes that have zero width or
height.

Sub ShowShapes()

Dim shp As Shape
Dim TestCell As Range
Dim resp As Long

For Each shp In ActiveSheet.Shapes
With shp
If .Width = 0 Or .Height = 0 Then
.Width = 40
.Height = 40
End If
End With

Set TestCell = Nothing
On Error Resume Next
Set TestCell = shp.TopLeftCell
On Error GoTo 0

If TestCell Is Nothing Then
'do nothing
Else
Application.Goto TestCell, Scroll:=True
resp = MsgBox("delete" & vbLf & shp.Name & vbLf & "at: " _
& TestCell.Address(0, 0), Buttons:=vbYesNo)
If resp = vbYes Then
shp.Delete
End If
End If
Next shp

End Sub



--
Regards,

OssieMac