Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using color in formula

Status
Not open for further replies.

ranebow

Programmer
Joined
Mar 8, 2003
Messages
110
Location
US
I've color coded numbers in my cells. And now I want to total by color....such as total of all red numbers, total of all blue numbers and total of all green numbers. Is there a way to do this?
 
ranebow,

There is no way to use worksheet formulas to determine color.

Did you use some objective criteria to color the cells? If so, you may be able to use a formula that uses similar objective cirteria.

Skip,

Want to get great answers to your Tek-Tips questions? Have a look at faq222-2244
 
You can do it with VBA. The following link may give you some idea:-

Summing The Values Of Cells With A Specific Color
(You need to scroll down a bit to get to it)

Note though, this does not work if the cells have been formatted using Conditional formatting.

Regards
Ken..............

----------------------------------------------------------------------------
[peace]It's easier to beg forgiveness than ask permission[2thumbsup]

----------------------------------------------------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top