View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default calculate sum of highlighted cells in a column

I guess you are stuck with the VBA solution found at Chip's site.

His SumByColor function is what you want.

You would copy and paste the Function to a general module in your workbook.

If you're not familiar with VBA and macros, see David McRitchie's site for
more on "getting started".

http://www.mvps.org/dmcritchie/excel/getstarted.htm

or Ron de De Bruin's site on where to store macros.

http://www.rondebruin.nl/code.htm


Gord

On Wed, 19 Mar 2008 17:16:00 -0700, ac experts
wrote:

Yes colored. I have a column of cells and i color them yellow with the fill
color button. Now I want to the sum of only the yellow cells, and if I color
more cells in the same column I want them to be totaled also.

"Gord Dibben" wrote:

What do you consider "highlighted"? Colored cells?

You would need to use VBA to SUM colored cells.

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

If the cells are colored due to Conditional Formatting you could SUM based upon
the CF criteria.

If you just want to get a SUM on the Status Bar try the following method if you
have Excel 2003 and all colored cells are same color...............

Select the column then EditFindFormatPattern. Select the pattern and OK.

In the Found Dialog hit SHIFT + DownArrow

On Status Bar see SUM = xxx


Gord Dibben MS Excel MVP

On Wed, 19 Mar 2008 16:40:00 -0700, ac experts <ac
wrote:

Is there a formula to add the sum of all highlighted cells only in a column
with both no fill and highlighted cells.