count conditional format

S

shital

i have given some conditional format to the cell. which
have red, green & black colour. Can it count the cell how
much cell in red colour & green & black.

Thanks in Advance

Shital
 
G

Guest

The same conditions you used for your conditional formatting could be used in the COUNTIF worksheet function, to count the number of occrrences of the conditions that set the cell as red, or green, etc.

Regards
 
G

Gord Dibben

Shital

You should be able to count these cells based upon the same parameters that
produced the colors through Conditional Formatting.

Otherwise see Chip Pearson's website for counting CF cells.

http://www.cpearson.com/excel/CFColors.htm

Here is the preface from this page.

"Unfortunately, the Color and ColorIndex properties of a Range don't return
the color of a cell that is displayed if Conditional formatting is applied to
the cell. Nor does it allow you to determine whether a conditional format is
currently in effect for a cell.
In order to determine these, you need code that will test the format
conditions. This page describes several VBA functions that will do this for
you."

Gord Dibben XL2002
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top