Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3
Default count colored cells in excel

Need a way to count the number of colored cells in a column that are filled
with a specific color via conditional formatting.

Found a VBA script on the internet for a ColorFunction code that will count
colored cells if manually filled. Doesn't work for those filled via
conditional formatting.

Any help would be appreciated.

Thanks!
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,480
Default count colored cells in excel

Hi

You need to count the cells matching the condition you set in your CF
formula.
Post your CF formula, and perhaps we can help you.

--
Regards
Roger Govier

"Maddog" wrote in message
...
Need a way to count the number of colored cells in a column that are
filled
with a specific color via conditional formatting.

Found a VBA script on the internet for a ColorFunction code that will
count
colored cells if manually filled. Doesn't work for those filled via
conditional formatting.

Any help would be appreciated.

Thanks!


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,651
Default count colored cells in excel

Look at the condition you have used for your CF, and use that in your
COUNTIF condition.
--
David Biddulph


"Maddog" wrote in message
...
Need a way to count the number of colored cells in a column that are
filled
with a specific color via conditional formatting.

Found a VBA script on the internet for a ColorFunction code that will
count
colored cells if manually filled. Doesn't work for those filled via
conditional formatting.

Any help would be appreciated.

Thanks!



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3
Default count colored cells in excel

Have quite a few. For just one column there are 6 separate conditions where
3 will return the same fill color. I've listed them below with the fill
color after each rule.

Cell Value = TODAY()+1095 Red

Cell Value between TODAY()+61 and TODAY()+90 Green

Cell Value = 0 Red

Cell Value between TODAY()+31 and TODAY()+60 Blue

Cell Value between TODAY()+1 and TODAY()+30 Yellow

Cell Value <= TODAY() Red




"Roger Govier" wrote:

Hi

You need to count the cells matching the condition you set in your CF
formula.
Post your CF formula, and perhaps we can help you.

--
Regards
Roger Govier

"Maddog" wrote in message
...
Need a way to count the number of colored cells in a column that are
filled
with a specific color via conditional formatting.

Found a VBA script on the internet for a ColorFunction code that will
count
colored cells if manually filled. Doesn't work for those filled via
conditional formatting.

Any help would be appreciated.

Thanks!



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,480
Default count colored cells in excel

Hi

Assuming your dates are in column A
For Red
=SUMPRODUCT(--(A1:A10=TODAY()+1095))+SUMPRODUCT(--(A1:A10<TODAY())*(A1:A10<""))
The 0 Value will get picked up along with <Today() as 0 will always be less
than today()

For Green
=SUMPRODUCT((A1:A1000=TODAY()+61)*(A1:A1000<=TODA Y()+90))
For Blue
=SUMPRODUCT((A1:A1000=TODAY()+31)*(A1:A1000<=TODA Y()+60))
for Yellow
=SUMPRODUCT((A1:A1000=TODAY()+1)*(A1:A1000<=TODAY ()+30))

--
Regards
Roger Govier

"Maddog" wrote in message
...
Have quite a few. For just one column there are 6 separate conditions
where
3 will return the same fill color. I've listed them below with the fill
color after each rule.

Cell Value = TODAY()+1095 Red

Cell Value between TODAY()+61 and TODAY()+90 Green

Cell Value = 0 Red

Cell Value between TODAY()+31 and TODAY()+60 Blue

Cell Value between TODAY()+1 and TODAY()+30 Yellow

Cell Value <= TODAY() Red




"Roger Govier" wrote:

Hi

You need to count the cells matching the condition you set in your CF
formula.
Post your CF formula, and perhaps we can help you.

--
Regards
Roger Govier

"Maddog" wrote in message
...
Need a way to count the number of colored cells in a column that are
filled
with a specific color via conditional formatting.

Found a VBA script on the internet for a ColorFunction code that will
count
colored cells if manually filled. Doesn't work for those filled via
conditional formatting.

Any help would be appreciated.

Thanks!





  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3
Default count colored cells in excel

Roger,

THANKS!

Green, blue, and yellow worked as written. Red ignored the cells that are
empty. The cell = 0 CF command colors those red. Perhaps 0 and null are not
the same thing for all commands? Removed the *(A1:A10<"") at the end of the
Red command and it seems to work now.

I'm not much of a formula guy, but do try to understand how they work. What
was the *(A1:A10<"") at the end of the Red line supposed to do?

As the * is a multiplication command, I don't understand why the formulas
don't multiply the number of blocks and return erronous results.





"Roger Govier" wrote:

Hi

Assuming your dates are in column A
For Red
=SUMPRODUCT(--(A1:A10=TODAY()+1095))+SUMPRODUCT(--(A1:A10<TODAY())*(A1:A10<""))
The 0 Value will get picked up along with <Today() as 0 will always be less
than today()

For Green
=SUMPRODUCT((A1:A1000=TODAY()+61)*(A1:A1000<=TODA Y()+90))
For Blue
=SUMPRODUCT((A1:A1000=TODAY()+31)*(A1:A1000<=TODA Y()+60))
for Yellow
=SUMPRODUCT((A1:A1000=TODAY()+1)*(A1:A1000<=TODAY ()+30))

--
Regards
Roger Govier

"Maddog" wrote in message
...
Have quite a few. For just one column there are 6 separate conditions
where
3 will return the same fill color. I've listed them below with the fill
color after each rule.

Cell Value = TODAY()+1095 Red

Cell Value between TODAY()+61 and TODAY()+90 Green

Cell Value = 0 Red

Cell Value between TODAY()+31 and TODAY()+60 Blue

Cell Value between TODAY()+1 and TODAY()+30 Yellow

Cell Value <= TODAY() Red




"Roger Govier" wrote:

Hi

You need to count the cells matching the condition you set in your CF
formula.
Post your CF formula, and perhaps we can help you.

--
Regards
Roger Govier

"Maddog" wrote in message
...
Need a way to count the number of colored cells in a column that are
filled
with a specific color via conditional formatting.

Found a VBA script on the internet for a ColorFunction code that will
count
colored cells if manually filled. Doesn't work for those filled via
conditional formatting.

Any help would be appreciated.

Thanks!



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Is there a way to count the number of different colored cells? MCM Excel Worksheet Functions 1 November 21st 06 06:16 PM
count colored cells? DKY Excel Worksheet Functions 21 January 19th 06 09:47 PM
count colored rows NoviceLois Excel Discussion (Misc queries) 1 December 28th 05 11:52 PM
Count non-colored cells Ken G Excel Discussion (Misc queries) 3 January 2nd 05 12:42 PM
Count or sum colored cells brightgirl Excel Worksheet Functions 2 December 7th 04 03:34 PM


All times are GMT +1. The time now is 07:29 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"