ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Sumif date=date (https://www.excelbanter.com/excel-worksheet-functions/207948-sumif-date%3Ddate.html)

Red

Sumif date=date
 
I have two worksheets. First has values and dates when entered.
eg, 123 1/1/2008
234 15/1/2008
456 3/2/2008
654 7/2/2008
876 16/4/2008

Second has month headings:- January Febuary........

What i want to do is sumif(ws1!date column,ws2!column header,ws1!values)
Hope this is clear! i tried using MONTH with no luck


T. Valko

Sumif date=date
 
Try this...

Sheet2 A1:L1 = Jan, Feb, Mar, Apr, ....Dec

Enter this formula in Sheet2 A2 and copy across to L2:

=SUMPRODUCT(--(MONTH(Sheet1!$B1:$B10)=COLUMNS($A2:A2)),Sheet1!$A 1:$A10)

Assuming there are no empty cells in your date column. An empty cell will
evaluate as month 1.

--
Biff
Microsoft Excel MVP


"red" wrote in message
...
I have two worksheets. First has values and dates when entered.
eg, 123 1/1/2008
234 15/1/2008
456 3/2/2008
654 7/2/2008
876 16/4/2008

Second has month headings:- January Febuary........

What i want to do is sumif(ws1!date column,ws2!column header,ws1!values)
Hope this is clear! i tried using MONTH with no luck




Red

Sumif date=date
 
Many thanks, works a treat!!

"T. Valko" wrote:

Try this...

Sheet2 A1:L1 = Jan, Feb, Mar, Apr, ....Dec

Enter this formula in Sheet2 A2 and copy across to L2:

=SUMPRODUCT(--(MONTH(Sheet1!$B1:$B10)=COLUMNS($A2:A2)),Sheet1!$A 1:$A10)

Assuming there are no empty cells in your date column. An empty cell will
evaluate as month 1.

--
Biff
Microsoft Excel MVP


"red" wrote in message
...
I have two worksheets. First has values and dates when entered.
eg, 123 1/1/2008
234 15/1/2008
456 3/2/2008
654 7/2/2008
876 16/4/2008

Second has month headings:- January Febuary........

What i want to do is sumif(ws1!date column,ws2!column header,ws1!values)
Hope this is clear! i tried using MONTH with no luck





T. Valko

Sumif date=date
 
You're welcome. Thanks for the feedback!

--
Biff
Microsoft Excel MVP


"red" wrote in message
...
Many thanks, works a treat!!

"T. Valko" wrote:

Try this...

Sheet2 A1:L1 = Jan, Feb, Mar, Apr, ....Dec

Enter this formula in Sheet2 A2 and copy across to L2:

=SUMPRODUCT(--(MONTH(Sheet1!$B1:$B10)=COLUMNS($A2:A2)),Sheet1!$A 1:$A10)

Assuming there are no empty cells in your date column. An empty cell will
evaluate as month 1.

--
Biff
Microsoft Excel MVP


"red" wrote in message
...
I have two worksheets. First has values and dates when entered.
eg, 123 1/1/2008
234 15/1/2008
456 3/2/2008
654 7/2/2008
876 16/4/2008

Second has month headings:- January Febuary........

What i want to do is sumif(ws1!date column,ws2!column
header,ws1!values)
Hope this is clear! i tried using MONTH with no luck








All times are GMT +1. The time now is 05:34 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com