total of colored rows

C

cpliu

How can I calculate the total number of rows in a specific color (eg.
yellow)? I'm trying to use "Countif" or "sumproduct" but I don't know how
to indicate color?


Thanks,

cpliu
 
C

cpliu

Frank,
Thanks for the helpful links. I tried =SUMPRODUCT(--(ColorIndex(A1:A100)=
3)) on my file and a new file, but I got #NAME? (Invalid name error??) both
times. What did I do wrong?

thanks,

cpliu
 
F

Frank Kabel

Hi
you also have to insert the UDF 'Colorindex' in one of your standard
modules. This only works with VBA
 
Top