combination of sumif and sobtotal

banane

New Member
Joined
May 10, 2013
Messages
5
I need your help with merging the sumif and the subtotal function.

But not in the way which most posts in forums are about. This is NOT about filters...


What I want to do is the following. I would like to use a normal sumif function with criteria in another column than the sumrange. The problem is, that there are some subtotals in the sumrange which I do not want to be added to the sum. Some of these Subtotal rows have valid values in the criteria_range. So they would be double counted.


I tried to replace the criteria in the sumifs by a IF function and have the subtotal function as the "true value" but this doesn't work:

IF(criteria_range = "name", SUBTOTAL(9, sum_range))


Thanks for your help!
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.

Forum statistics

Threads
1,215,025
Messages
6,122,734
Members
449,094
Latest member
dsharae57

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
Back
Top