Hi all, Here's some fun code. It will display all 137 Auto Shapes at 1/2 second intervals untill finished.
Public Sub DisplayAutoShapes()
Dim sh As Shape
Dim i As Integer
Set sh = ActiveSheet.Shapes.AddShape(1, 100, 100, 72, 72)
For i = 1 To 137
sh.AutoShapeType = i
sh.Visible = True
ActiveSheet.Cells(1, 1).Value = sh.AutoShapeType
Delay 0.5
Next i
MsgBox "Finished"
End Sub
Public Sub Delay(rTime As Single)
'delay rtime seconds (min=.01, max=300)
Dim OldTime As Variant
'safety net
If rTime < 0.01 Or rTime > 300 Then rTime = 1
OldTime = Timer
Do
DoEvents
Loop Until Timer - OldTime > rTime
End Sub
Public Sub DisplayAutoShapes()
Dim sh As Shape
Dim i As Integer
Set sh = ActiveSheet.Shapes.AddShape(1, 100, 100, 72, 72)
For i = 1 To 137
sh.AutoShapeType = i
sh.Visible = True
ActiveSheet.Cells(1, 1).Value = sh.AutoShapeType
Delay 0.5
Next i
MsgBox "Finished"
End Sub
Public Sub Delay(rTime As Single)
'delay rtime seconds (min=.01, max=300)
Dim OldTime As Variant
'safety net
If rTime < 0.01 Or rTime > 300 Then rTime = 1
OldTime = Timer
Do
DoEvents
Loop Until Timer - OldTime > rTime
End Sub