sumproduct formula returns #name error

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi. I am trying to get a sumproduct formula that will look at the date in one column and if its the correct month, total values in a second column. I am getting #Name returned with the formula I have. Can someone tell mewhat I did wrong?


=SUMPRODUCT(--(A2:A500=MONTH(3)),D2:D500)

A D
Date Amount
03/14/04 62.11
04/04/04 101.54


TIA


Todd
 
Hi,

try,

=SUMPRODUCT(--(MONTH(A2:A500)=3),--(YEAR(A2:A500)=2004),D2:D500)

Notice I've added the year as a criteria. This will ensure that it
totals the values for the relevant year and ignore any blank cells in
Column A.

Hope this helps!
 
Toddù wrote . . .
Hi. I am trying to get a sumproduct formula that will look at the
date in one column and if its the correct month, total values in a
second column. I am getting #Name returned with the formula I
have. Can someone tell mewhat I did wrong?

=SUMPRODUCT(--(A2:A500=MONTH(3)),D2:D500)
...

Given this formula, it's very likely you have a #NAME? error in one o
more cells in either A2:A500 or D2:D500. What do the formulas

=SUM(A2:A500)

and

=SUM(D2:D500)

return? Also, I'd guess you want

=SUMPRODUCT(--(MONTH(A2:A500)=3),D2:D500
 
=SUMPRODUCT(--(MONTH(A2:A500)=3),D2:D500)



--

Regards,

Peo Sjoblom

(No private emails please, for everyone's
benefit keep the discussion in the newsgroup/forum)


Todd said:
Hi. I am trying to get a sumproduct formula that will look at the date in
one column and if its the correct month, total values in a second column. I
am getting #Name returned with the formula I have. Can someone tell mewhat
I did wrong?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top