ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   sumif help (https://www.excelbanter.com/excel-worksheet-functions/36406-sumif-help.html)

stuarthow

sumif help
 

Hi

Need some help with the SUMIF() function on Excel 2003 please:

I’m using this function as per example –

=SUMIF(month(B5:B12),month(B15),C5:C12)

where B5:B12 are regular dates (dd/mm/yyyy), B15 is a ‘month’ date (mmm
yyyy) and C5:C12 are ordinary numbers.

When entered, I get returned the warning box ‘The formula you typed
contains an error’

Help would be gratefully welcome.
Stuart


--
stuarthow
------------------------------------------------------------------------
stuarthow's Profile: http://www.excelforum.com/member.php...o&userid=25417
View this thread: http://www.excelforum.com/showthread...hreadid=388975


Aladin Akyurek

B15: 1-Jul-04

Then invoke:

=SUMIF($B$5:$B$12,"="&B15,$C$5:$C$12)-SUMIF($B$5:$B$12,""&EOMONTH(B15,0),$C$5:$C$12)

EOMONTH requires the Analysis Toolpak add-in (see Tools|Add-Ins)

stuarthow wrote:
Hi

Need some help with the SUMIF() function on Excel 2003 please:

I’m using this function as per example –

=SUMIF(month(B5:B12),month(B15),C5:C12)

where B5:B12 are regular dates (dd/mm/yyyy), B15 is a ‘month’ date (mmm
yyyy) and C5:C12 are ordinary numbers.

When entered, I get returned the warning box ‘The formula you typed
contains an error’

Help would be gratefully welcome.
Stuart



--

[1] The SumProduct function should implicitly coerce the truth values to
their Excel numeric equivalents.
[2] The lookup functions should have an optional argument for the return
value, defaulting to #N/A in its absence.

aristotle

Does this work?

=SUM(MONTH(B5:B12)=MONTH(B15),C5:C12)

Once entered don't just hit enter, use Ctrl+Shift+Enter and it should
generate an array formula.

Regards,
A


"stuarthow" wrote:


Hi

Need some help with the SUMIF() function on Excel 2003 please:

Im using this function as per example €“

=SUMIF(month(B5:B12),month(B15),C5:C12)

where B5:B12 are regular dates (dd/mm/yyyy), B15 is a €˜month date (mmm
yyyy) and C5:C12 are ordinary numbers.

When entered, I get returned the warning box €˜The formula you typed
contains an error

Help would be gratefully welcome.
Stuart


--
stuarthow
------------------------------------------------------------------------
stuarthow's Profile: http://www.excelforum.com/member.php...o&userid=25417
View this thread: http://www.excelforum.com/showthread...hreadid=388975



stuarthow


Thanks Aladin / aristotle!

Aladin's code works fine, although can't say I understand why, will
have a play!

aristotle's sums the whole range of numbers, think that when the
argument returns true the whole range C5:C12 is summed.

Thanks again
Stu


--
stuarthow
------------------------------------------------------------------------
stuarthow's Profile: http://www.excelforum.com/member.php...o&userid=25417
View this thread: http://www.excelforum.com/showthread...hreadid=388975



All times are GMT +1. The time now is 07:00 PM.

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