Formulas by Cell Color

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"

AlphaFrog

MrExcel MVP
Joined
Sep 2, 2009
Messages
16,406
I don't think there's a specific function for that.

If you want to sum cells that are colored by Conditional Formatting, you can duplicate the Conditional Formatting "conditions" within a formula and sum cells that match those conditions.

If you have "manually" formatted certain cells (say every odd row), and you want to sum cells in a given range that have the format, often there are ways to replicate that format pattern e.g. every odd cell in a range.

If you give more specifics on what exactly you want to do and how your data is configured (examples are always good), usually someone around here will come up with a solution.
 

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
48,590
Office Version
  1. 365
Platform
  1. Windows
Bill

Welcome to the MrExcel board!

Probably best to do this via a macro but you may wish to try this work-around.

Given my data and colouring in column A below:

1. Select B1

2. Pre Excel 2007: Insert|Name|Define...|Names in Workbook:
Excel 2007: Formulas ribbon|Name Manager|New|Name:

3. Enter CelCol as the name

4. Refers to: =GET.CELL(63,OFFSET(INDIRECT("RC",FALSE),0,-1))

5. Confirm and close out of the Name dialog.

6. Put the colours you want to sum by in column D.

7. Enter the formulas shown and copy down.


Excel Workbook
ABCDEFG
1133337
224303
3304311
4443
5543
6633
7
Sum by Cell Colour
 

Watch MrExcel Video

Forum statistics

Threads
1,130,342
Messages
5,641,583
Members
417,223
Latest member
jelena_

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