Please help with Count
See edited (air)code below.
HTH,
Keith
"Please Help" wrote in message
...
Hello all,
I have a macro to delete the shapes in an active worksheet. After the
shapes are deleted, users will receive a message that they have been
deleted.
In the message, I would like to insert the number of shapes that were
deleted. Can someone help me with counting those deleted shapes?
Below is my current code:
Dim cMarks As Shape
Dim cCount as Integer
cCount = 0
For Each cMarks In ActiveSheet.Shapes
If cMarks.Type = 13 Then
cMarks.Delete
cCount = cCount+1
End if
Next cMarks
MsgBox "You have removed " & cstr(cCount) & " check marks in Worksheet
'" &
ActiveSheet.Name & "'."
Thanks.
|