#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 470
Default MONTH() question

I have the following formula in workbook BUDGET:

=SUMPRODUCT(--('[Paycheck.xls]2007'!$B$10:$AA$10=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

As you can see, it is looking in workbook PAYCHECKS for certain data. In
the PAYCHECKS workbook, range B10:AA10 contains a date (each column in row)
that a paycheck is received. The range B17:AA17 is the gross pay of each
paycheck.

MONTH(A3) is the date , ie 1/1/07 (formatted JAN-07) in BUDGET.

I am wanting to take the month value of A3 and sum the corresponding gross
pay recieved within that month. However, I do not know how to, or if you
can, use the MONTH function for a range, ie MONTH(B17:AA17).

Is there some way to do this or do I need to figure something else out?

Thanks,
Les
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,339
Default MONTH() question

try:

=SUMPRODUCT(--(MONTH('[Paycheck.xls]2007'!$B$10:$AA$10)=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

"WLMPilot" wrote:

I have the following formula in workbook BUDGET:

=SUMPRODUCT(--('[Paycheck.xls]2007'!$B$10:$AA$10=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

As you can see, it is looking in workbook PAYCHECKS for certain data. In
the PAYCHECKS workbook, range B10:AA10 contains a date (each column in row)
that a paycheck is received. The range B17:AA17 is the gross pay of each
paycheck.

MONTH(A3) is the date , ie 1/1/07 (formatted JAN-07) in BUDGET.

I am wanting to take the month value of A3 and sum the corresponding gross
pay recieved within that month. However, I do not know how to, or if you
can, use the MONTH function for a range, ie MONTH(B17:AA17).

Is there some way to do this or do I need to figure something else out?

Thanks,
Les

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,651
Default MONTH() question

MONTH() gives a number from 1 to 12, so it doesn't make sense to format that
as a date (where it would appear as 1st Jan 1900 to 12th Jan 1900,
inclusive), but perhaps you mean that A3, rather than MONTH(A3), is
formatted as a date?
If your range B10:AA10 contains real dates, you can't realistically test
that directly for equality with your month 1 to 12 in MONTH(A3), so it may
make sense to change your formula to:
=SUMPRODUCT(--(MONTH('[Paycheck.xls]2007'!$B$10:$AA$10)=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17).
--
David Biddulph

"WLMPilot" wrote in message
...
I have the following formula in workbook BUDGET:

=SUMPRODUCT(--('[Paycheck.xls]2007'!$B$10:$AA$10=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

As you can see, it is looking in workbook PAYCHECKS for certain data. In
the PAYCHECKS workbook, range B10:AA10 contains a date (each column in
row)
that a paycheck is received. The range B17:AA17 is the gross pay of each
paycheck.

MONTH(A3) is the date , ie 1/1/07 (formatted JAN-07) in BUDGET.

I am wanting to take the month value of A3 and sum the corresponding gross
pay recieved within that month. However, I do not know how to, or if you
can, use the MONTH function for a range, ie MONTH(B17:AA17).

Is there some way to do this or do I need to figure something else out?

Thanks,
Les



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 470
Default MONTH() question

Thanks, just what I was looking for!!!

"Toppers" wrote:

try:

=SUMPRODUCT(--(MONTH('[Paycheck.xls]2007'!$B$10:$AA$10)=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

"WLMPilot" wrote:

I have the following formula in workbook BUDGET:

=SUMPRODUCT(--('[Paycheck.xls]2007'!$B$10:$AA$10=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

As you can see, it is looking in workbook PAYCHECKS for certain data. In
the PAYCHECKS workbook, range B10:AA10 contains a date (each column in row)
that a paycheck is received. The range B17:AA17 is the gross pay of each
paycheck.

MONTH(A3) is the date , ie 1/1/07 (formatted JAN-07) in BUDGET.

I am wanting to take the month value of A3 and sum the corresponding gross
pay recieved within that month. However, I do not know how to, or if you
can, use the MONTH function for a range, ie MONTH(B17:AA17).

Is there some way to do this or do I need to figure something else out?

Thanks,
Les

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 470
Default MONTH() question

One other little question: What are the two dashes for prior to the first
MONTH() function?

Les



"Toppers" wrote:

try:

=SUMPRODUCT(--(MONTH('[Paycheck.xls]2007'!$B$10:$AA$10)=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

"WLMPilot" wrote:

I have the following formula in workbook BUDGET:

=SUMPRODUCT(--('[Paycheck.xls]2007'!$B$10:$AA$10=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

As you can see, it is looking in workbook PAYCHECKS for certain data. In
the PAYCHECKS workbook, range B10:AA10 contains a date (each column in row)
that a paycheck is received. The range B17:AA17 is the gross pay of each
paycheck.

MONTH(A3) is the date , ie 1/1/07 (formatted JAN-07) in BUDGET.

I am wanting to take the month value of A3 and sum the corresponding gross
pay recieved within that month. However, I do not know how to, or if you
can, use the MONTH function for a range, ie MONTH(B17:AA17).

Is there some way to do this or do I need to figure something else out?

Thanks,
Les



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,651
Default MONTH() question

Double unary minus. Converts the logical TRUE or FALSE to number 0 or 1 so
that it can be multiplied..
--
David Biddulph

"WLMPilot" wrote in message
...
One other little question: What are the two dashes for prior to the first
MONTH() function?

Les



"Toppers" wrote:

try:

=SUMPRODUCT(--(MONTH('[Paycheck.xls]2007'!$B$10:$AA$10)=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

"WLMPilot" wrote:

I have the following formula in workbook BUDGET:

=SUMPRODUCT(--('[Paycheck.xls]2007'!$B$10:$AA$10=MONTH(A3)),'[Paycheck.xls]2007'!$B$17:$AA$17)

As you can see, it is looking in workbook PAYCHECKS for certain data.
In
the PAYCHECKS workbook, range B10:AA10 contains a date (each column in
row)
that a paycheck is received. The range B17:AA17 is the gross pay of
each
paycheck.

MONTH(A3) is the date , ie 1/1/07 (formatted JAN-07) in BUDGET.

I am wanting to take the month value of A3 and sum the corresponding
gross
pay recieved within that month. However, I do not know how to, or if
you
can, use the MONTH function for a range, ie MONTH(B17:AA17).

Is there some way to do this or do I need to figure something else out?

Thanks,
Les



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
sum if - month question paula k Excel Discussion (Misc queries) 3 December 14th 06 09:29 PM
Dates Formatting Question - What if you do not know month and/or d elfmajesty Excel Discussion (Misc queries) 4 October 12th 06 08:37 PM
Month & year question RGB Excel Discussion (Misc queries) 4 May 26th 06 12:54 PM
End of Month question Purple_Jack New Users to Excel 5 May 31st 05 07:12 PM
Month and Days question Anthony Slater Excel Discussion (Misc queries) 2 February 22nd 05 12:29 PM


All times are GMT +1. The time now is 01:48 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"