Array formula as SUMPRODUCT argument

foreveryone

New Member
Joined
Apr 20, 2018
Messages
8
Is this possible?

I have an array of IFs that's matches 1 row and returns a 4 column range, so 4 numbers. I can sum this fine but when I try passing it as the first argument in to sumproduct, I get a value! error. Here's some sample data:

[TABLE="width: 500"]
<tbody>[TR]
[TD]1
[/TD]
[TD]A
[/TD]
[TD]B
[/TD]
[TD]C
[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[/TR]
[TR]
[TD]2
[/TD]
[TD]apple
[/TD]
[TD]mon
[/TD]
[TD]1
[/TD]
[TD]2
[/TD]
[TD]3
[/TD]
[TD]4
[/TD]
[/TR]
[TR]
[TD]3
[/TD]
[TD]apple
[/TD]
[TD]tues
[/TD]
[TD]1
[/TD]
[TD]2
[/TD]
[TD]3
[/TD]
[TD]5
[/TD]
[/TR]
[TR]
[TD]4
[/TD]
[TD]lemon
[/TD]
[TD]mon
[/TD]
[TD]5
[/TD]
[TD]2
[/TD]
[TD]3
[/TD]
[TD]6
[/TD]
[/TR]
[TR]
[TD]5
[/TD]
[TD]orange
[/TD]
[TD]mon
[/TD]
[TD]5
[/TD]
[TD]2
[/TD]
[TD]3
[/TD]
[TD]1
[/TD]
[/TR]
</tbody>[/TABLE]

So I have {SUMPRODUCT(IF(A2:A5="Apple",IF(B2:B5="mon",C2:F5)),Z1:Z4})}

Where Z1:Z4 is some other 4 numbers.

In my actual data I have 4 IFs and looking at more cells but of course, shouldn't matter!

Many thanks
 

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.
Welcome to Mr Excel forum

Try
=SUMPRODUCT((A2:A5="Apple")*(B2:B5="mon")*C2:F5*Z1:Z4)
confirmed with just Enter

Hope this helps

M.
 
Upvote 0
Hi!

You can try too this small modification in your formula:

Use Ctrl+Shift+Enter to enter the formula

=SUM(IF(A2:A5="apple",IF(B2:B5="mon",C2:F5*Z1:Z4)))

Markmzz
 
Upvote 0

Forum statistics

Threads
1,223,908
Messages
6,175,306
Members
452,633
Latest member
DougMo

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