Formula to calculate total number of colored cells

barim

Board Regular
Joined
Apr 19, 2006
Messages
176
I need a formula that would calculate a total number of cells that are colored in each column. For example, in the cell C100 should be formula that would give me a count of cells that has background color green. There are no multiple colors throughout the worksheet, it is only one color - green. Total numbers should be placed from cell C100 until N100 and my data is within range of C2:N99. Is there any way to do this using formula instead of VBA? If there is no any formula solution, then I will have to use VBA solution.

Thank you in advance.
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
Are you using conditional formatting to color the cells? Because there is no formula that can detect a cell color. If it's conditional formatting formula applying the color, then we can work with that to get a count.
 
Upvote 0
dreid1011, thank you for your reply. I wish we have countif formula that can calculate this. To answer your question, I've got these highlighted cells through running a macro. I actually found solution by inserting one of Ozgrid's custom functions which works perfectly for this case and it is relatively fast. I wish Microsoft builds us formula instead of having involved these custom built functions.
Thanks again for your reply.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top