Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Sumif formula using a date as a criteria 1

Status
Not open for further replies.

itechC

Programmer
Feb 13, 2003
71
CA
HI all,

I am trying to get the sum of a column using the sumif formula. This is the formula i am using: =SUMIF(Sheet2!B4:B34,Sheet1!<B4,Sheet2!D4:D34).

i want to get the sum of the col if the date in col b is less then July 7, 2007. I keep getting errors in my formula and if i use brackets i get a 0. But if i type in the date manually instead of using B4 the formula works.

Any ideas why?
 
Your syntax is off.

Try this:
[COLOR=blue white]=SUMIF(Sheet2!B4:B34, "<"&B4, Sheet2!D4:D34)[/color]

[tt]_____
[blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ 181-2886 before posting.
 
Whoops - I forgot the Sheet1 reference in the second argument:

[COLOR=blue white]=SUMIF(Sheet2!B4:B34, "<"&Sheet1!B4, Sheet2!D4:D34)[/color]

[tt]_____
[blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ 181-2886 before posting.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top