How to sum up columns for those adjacent columns that are conditionally highlighted.

Stevekent

Board Regular
Joined
Jul 24, 2013
Messages
92
Office Version
  1. 365
Platform
  1. Windows
I've 2 columns, say A and B, each has 10 rows of data. Column A has
conditional formatting and A1, A2, A4, A8 and A9 are highlighted
conditionally. B1 to B10 all got figures. Now, how can I sum up column B
only for those Column A that are highlighted.
 

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
48,580
Office Version
  1. 365
Platform
  1. Windows
What is the conditional formatting rule applied to column A?
 

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
48,580
Office Version
  1. 365
Platform
  1. Windows
if the cell >0, then fill the cell in colour
Then you could use that same condition to sum the column B values:
Excel Formula:
=SUMIF(A1:A10,">0",B1:B10)

or if your Excel 365 has the FILTER function then another option would be
Excel Formula:
=SUM(FILTER(B1:B10,A1:A10>0,0))
 

Watch MrExcel Video

Forum statistics

Threads
1,130,253
Messages
5,641,120
Members
417,194
Latest member
Excellent Excel

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