View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Peo Sjoblom[_2_] Peo Sjoblom[_2_] is offline
external usenet poster
 
Posts: 964
Default SUMIF with date ranges

=SUMPRODUCT(--(A1:A100=C1-60),--(A1:A100<C1-30),D1:D100)


adjust to fit

you might also want this


=SUMPRODUCT(--(A1:A100=C1-60),--(A1:A100<=C1-30),D1:D100)


that would be the 30-60 days, the rest you should be able to figure out
yourself

--


Regards,


Peo Sjoblom

"Vivian0102" wrote in message
...
Hi,

I need help with a formula to add the sum of values in column D if a date
in
column A is between 31-60 before C1 (A100), or between 61-90 before C1
(B100), or between 91-120 before C1 (C100) and so fort.

Example:

C1= 10/31/08

A1=8/31/08 D1= $1,200
A2=9/30/08 D2= $1,200
A3=9/30/08 D3= $1,200
A4=10/31/08 D4= $1,200

A100= Total of 30-60 B100= Total of 60-90 C100= Total of 90-120