ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Conditional Formating Question (https://www.excelbanter.com/excel-worksheet-functions/134200-conditional-formating-question.html)

Carl

Conditional Formating Question
 

I have some cells that are conditionally formated to fill Blue, Green, or Red.

Is it possible for a macro or a formula to tell me the count of cells that
are Blue, Green, and Red over a given range of cells ?

Thank you in advance.

Toppers

Conditional Formating Question
 
See:

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


"carl" wrote:


I have some cells that are conditionally formated to fill Blue, Green, or Red.

Is it possible for a macro or a formula to tell me the count of cells that
are Blue, Green, and Red over a given range of cells ?

Thank you in advance.


Gord Dibben

Conditional Formating Question
 
carl

The normal methods of determining the colorindex of a cell won't work with cells
colored by CF.

Can be done via VBA

See Chip Pearson's site for code.

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

Might be easier to do a COUNTIF or similar on the conditions that created the
colored cells.


Gord Dibben MS Excel MVP

On Fri, 9 Mar 2007 07:45:16 -0800, carl wrote:


I have some cells that are conditionally formated to fill Blue, Green, or Red.

Is it possible for a macro or a formula to tell me the count of cells that
are Blue, Green, and Red over a given range of cells ?

Thank you in advance.



Carl

Conditional Formating Question
 
Thank You. I am not sure can do what I need. Basically I need to count the
number of cells in a range that are CF'ed Blue, Green. How can I use this
code to help me do that ?

"Toppers" wrote:

See:

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


"carl" wrote:


I have some cells that are conditionally formated to fill Blue, Green, or Red.

Is it possible for a macro or a formula to tell me the count of cells that
are Blue, Green, and Red over a given range of cells ?

Thank you in advance.


Toppers

Conditional Formating Question
 
Carl,
My mistake: refer to the site that Gord pointed to in his reply:

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

Use the CountOfCF function:


=CountOfCF(A1:A20,3)

will give count of RED cells in range A1:A20



"carl" wrote:

Thank You. I am not sure can do what I need. Basically I need to count the
number of cells in a range that are CF'ed Blue, Green. How can I use this
code to help me do that ?

"Toppers" wrote:

See:

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


"carl" wrote:


I have some cells that are conditionally formated to fill Blue, Green, or Red.

Is it possible for a macro or a formula to tell me the count of cells that
are Blue, Green, and Red over a given range of cells ?

Thank you in advance.



All times are GMT +1. The time now is 10:12 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com