Sum horizontal and vertical based on criteria

cwallace70

Board Regular
Joined
Mar 7, 2011
Messages
172
I am trying to get the sum of a product in column A:A with the amounts in columns AD:JN.

I tried this sumif formula
=SUM(IF('Apr 8-CM GL v ACS Recon Detail'!A:A=$A13,$AD:$JN))
and it returns zero.

I tried sumproduct
=SUMPRODUCT('Apr 8-CM GL v ACS Recon Detail'!AD:JN,'Apr 8-CM GL v ACS Recon Detail'!A:A=Sumary!A:A)
and it a returned a #N/A

I hope someone can help me with these formulas.

On sheet 1 a product A in col A:A is equal to a product on sheet 2 col A:A, then sum AD:JN

Thank you
 

Excel Facts

Workdays for a market open Mon, Wed, Friday?
Yes! Use "0101011" for the weekend argument in NETWORKDAYS.INTL or WORKDAY.INTL. The 7 digits start on Monday. 1 means it is a weekend.
I tried this sumif formula
=SUM(IF('Apr 8-CM GL v ACS Recon Detail'!A:A=$A13,$AD:$JN))
To make that work you need to enter that as an array formula.

1. Type the formula in a cell
2. Press and hold CTRL and SHIFT
3. Press Enter

Your formula has now a beginning and ending curly bracket. {=formula}
Don't eneter these characters yourself.

https://exceljet.net/glossary/array-formula


[Table="width:, class:head"][tr=bgcolor:#E0E0F0][th] [/th][th]
A
[/th][th]
B
[/th][th]
C
[/th][th]
D
[/th][th]
E
[/th][th]
F
[/th][th]
G
[/th][th]
H
[/th][/tr]
[tr=bgcolor:#FFFFFF][td=bgcolor:#E0E0F0]
1
[/td][td][/td][td]A[/td][td]
1​
[/td][td]
5​
[/td][td][/td][td][/td][td]A[/td][td]
16​
[/td][/tr]


[tr=bgcolor:#FFFFFF][td=bgcolor:#E0E0F0]
2
[/td][td][/td][td]B[/td][td]
2​
[/td][td]
6​
[/td][td][/td][td][/td][td][/td][td][/td][/tr]


[tr=bgcolor:#FFFFFF][td=bgcolor:#E0E0F0]
3
[/td][td][/td][td]A[/td][td]
3​
[/td][td]
7​
[/td][td][/td][td][/td][td][/td][td][/td][/tr]


[tr=bgcolor:#FFFFFF][td=bgcolor:#E0E0F0]
4
[/td][td][/td][td]D[/td][td]
4​
[/td][td]
8​
[/td][td][/td][td][/td][td][/td][td][/td][/tr]
[/table]
[Table="width:, class:grid"][tr][td]Sheet: Sheet83[/td][/tr][/table]

Array formula in cell H1:
=SUM(IF(B1:B4=G1,C1:D4,0))
 
Upvote 0

Forum statistics

Threads
1,223,911
Messages
6,175,324
Members
452,635
Latest member
laura12345

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