Lots of info at the link pertaining to calculations based on color formats:

http://www.cpearson.com/Excel/colors.aspx

IMHO, this should be avoided as it doesn't work the way you need it to work!