SUMPRODUCT Returning N/A#

coliervile

Well-known Member
Joined
May 19, 2006
Messages
724
Good day everyone-

I'm trying to sum ($AC$7:$BL$7) if ($W$1:$KH$1) is the month is 10 or October.

Code:
=SUMPRODUCT((MONTH($W$1:$KH$1)=10)*($AC$7:$BL$7))

The dates in range ($W$1:$KH$1) are formatted as dates.

Code:
=SUMPRODUCT((MONTH($W$1:$KH$1)=10)*(YEAR($W$1:$KH$1)=2015)*($AC$7:$BL$7))

I get a N/A# error on both.


Best regards,
Charlie
 

Excel Facts

Shade all formula cells
To shade all formula cells: Home, Find & Select, Formulas to select all formulas. Then apply a light fill color.
I get a N/A# error on both.

Hi Charlie

... as you should. The number of columns is not the same in the ranges. W:KH has 272 columns, AC:BL has 36 columns, which results in an error (and makes no sense).

Maybe you can explain your problem with more details. Maybe a simple example with a few columns?
 
Upvote 0
Thanks "pgc01" for looking at my question. You response makes sense and when i adjusted the formula I got the correct result. What I'm trying to do is sum various rows for each month of the Fiscal Year using the calendar dates in the range of W1:KH1. My problem is this... the data below W1:KH1 that I want to sum is offset from column to column in rows 3 to 52 it's not in any order. Which is a real pain.

Charlie
 
Upvote 0
Could post a small example, just some rows and columns, that shows what you need?

May someone can figure out a solution.
 
Upvote 0
"pgc01" unfortunately I'm on a work computer and I can't download Jeanie to post a sampling of my work.
 
Upvote 0

Forum statistics

Threads
1,214,985
Messages
6,122,602
Members
449,089
Latest member
Motoracer88

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