Forum Discussion
khoughton
Jun 28, 2022Copper Contributor
Counting specific shapes and colors
I have a spreadsheet that among text data, has shapes. These shapes are all circles and are filled with five different colors. What I am attempting to do is find out a way to have excel count the n...
NikolinoDE
Jun 29, 2022Platinum Contributor
Is it not possible to count all shapes that have the same name with the name description?
..just a thought :).
untested...
Option Explicit
Sub countnameshape()
Dim intAnzahl As Integer, sh As Shape
For Each sh In ActiveSheet.Shapes
If sh.Name Like "Shape*" Then intAnzahl = intAnzahl + 1
Next
Debug.Print intAnzahl
End Sub
If it's not what you're looking for, please just ignore it :).
I know I don't know anything (Socrates)
- khoughtonJun 30, 2022Copper Contributor
NikolinoDE Thanks for the reply. I'll try what you posted.