Suming cell with colour.

Peter1973

Well-known Member
Joined
May 13, 2006
Messages
942
I have a row of cells A1:A10 then in A11 I have simple formula
=SUM(A1:A10)

Is there a formula I could use that would detect if one of the cells was fomated to a certain colour ie yellow that would then add 8 to the answer.

So if A1:A10 total was 35 but A8 was formatted yellow the toal would be 43.
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December

Peter1973

Well-known Member
Joined
May 13, 2006
Messages
942
Thanks for the help my knowledge of vba is small enough to fit on a stamp but im trying to get to grips with the info on the links.

Thanks
 

Greg Truby

MrExcel MVP
Joined
Jun 19, 2002
Messages
10,022
Obviously the relevant one of Chip's UDF's listed there is SumByColor. This one is a very well-known UDF by now. So if you just do a search here on SumByColor you'll get plenty of threads related to its usage/implementation.
 

Forum statistics

Threads
1,175,973
Messages
5,900,643
Members
434,840
Latest member
ediaz13

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
Top