Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default Sum only numbers in red font color

not that elegant, but this will work...

1. Built a very easy function that returns the colorindex property of a
particular cell; ie:

Function CellColor(Cellref As String)
CellColor = Range(Cellref).Font.ColorIndex
End Function

2. Beside the column you want evaluated (or elsewhere) use the above
function to return the colorindex of the cell; ie:

A B
10 =CellColor(CELL("address",A1))
20 =CellColor(CELL("address",A2))
30 =CellColor(CELL("address",A3))

3. Use SUMIF to calculate the lot; ie:

=SUMIF(B1:B3,3,A1:A3)

In the above case, the "3" checks for excel's default version of the color
red.

HWH
------

"Cathy Floyd" wrote in message
...
I am looking for a formula to sum only the numbers that
appear in red font color. I tried using this formula: =IF
((font.color=_RGB(255,0,0)),SUM(K5:K25060),0), but it did
not work. Any suggestions?



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
SUM numbers of a certain font color gudencough Excel Discussion (Misc queries) 4 May 21st 10 03:58 PM
Font color for negative numbers Regards New Users to Excel 2 October 19th 07 01:58 AM
Font color for negative numbers Regards New Users to Excel 1 October 19th 07 01:57 AM
Sum only numbers in red font color John Wilson Excel Programming 0 August 1st 03 08:20 PM
Sum only numbers in red font color Bob Phillips[_5_] Excel Programming 0 August 1st 03 08:19 PM


All times are GMT +1. The time now is 08:41 AM.

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

About Us

"It's about Microsoft Excel"