Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Gohan51D
 
Posts: n/a
Default Count number of cells of a particular month in a column of dates


Cells D2-D15 contains a list of dates ranging from Jan through May. I
need D16 to count how many cells in that column contain dates in March.
I am assuming it is a COUNTIF function but I have not been able to find
a solution in any texts or on the internet. Any type of help is
appreciated.

Gohan51D


--
Gohan51D
------------------------------------------------------------------------
Gohan51D's Profile: http://www.excelforum.com/member.php...o&userid=32274
View this thread: http://www.excelforum.com/showthread...hreadid=521940

  #2   Report Post  
Posted to microsoft.public.excel.misc
Paul Lautman
 
Posts: n/a
Default Count number of cells of a particular month in a column of dates

Gohan51D wrote:
Cells D2-D15 contains a list of dates ranging from Jan through May. I
need D16 to count how many cells in that column contain dates in
March. I am assuming it is a COUNTIF function but I have not been
able to find a solution in any texts or on the internet. Any type of
help is appreciated.

Gohan51D


=SUMPRODUCT((MONTH(D2:D15)=3)*1)


  #3   Report Post  
Posted to microsoft.public.excel.misc
Gohan51D
 
Posts: n/a
Default Count number of cells of a particular month in a column of dates


Thanks I will give them a try

Gohan51D


--
Gohan51D
------------------------------------------------------------------------
Gohan51D's Profile: http://www.excelforum.com/member.php...o&userid=32274
View this thread: http://www.excelforum.com/showthread...hreadid=521940

  #4   Report Post  
Posted to microsoft.public.excel.misc
Gohan51D
 
Posts: n/a
Default Count number of cells of a particular month in a column of dates


The formula seems to work but I didn't mention that the column of dates
also contains text. When I remove the text the formula works great but
once the text is entered I get #VALUE!, how can I ignore all text.

Gohan51D


--
Gohan51D
------------------------------------------------------------------------
Gohan51D's Profile: http://www.excelforum.com/member.php...o&userid=32274
View this thread: http://www.excelforum.com/showthread...hreadid=521940

  #5   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson
 
Posts: n/a
Default Count number of cells of a particular month in a column of dates

Maybe you could use something like:

=SUM(IF(ISNUMBER(D2:D15),--(MONTH(D2:D15)=1)))

This is an array formula. Hit ctrl-shift-enter instead of enter. If you do it
correctly, excel will wrap curly brackets {} around your formula. (don't type
them yourself.)

Adjust the range to match--but you can't use the whole column



Gohan51D wrote:

The formula seems to work but I didn't mention that the column of dates
also contains text. When I remove the text the formula works great but
once the text is entered I get #VALUE!, how can I ignore all text.

Gohan51D

--
Gohan51D
------------------------------------------------------------------------
Gohan51D's Profile: http://www.excelforum.com/member.php...o&userid=32274
View this thread: http://www.excelforum.com/showthread...hreadid=521940


--

Dave Peterson


  #6   Report Post  
Posted to microsoft.public.excel.misc
Gohan51D
 
Posts: n/a
Default Count number of cells of a particular month in a column of dates


The formula seems to work but I didn't mention that the column of dates
also contains text. When I remove the text the formula works great but
once the text is entered I get #VALUE!, how can I ignore all text.

This is the formula used. If any text in D2-D19 then I get #VALUE!
If not text it works great.

=SUMPRODUCT(--ISNUMBER(D2:D19),--(MONTH(D2:D19)=2)*1)

=SUM(IF(MONTH(E2:E18)=2,1,0)) This also worked but with the same text
problem.


Gohan51D


--
Gohan51D
------------------------------------------------------------------------
Gohan51D's Profile: http://www.excelforum.com/member.php...o&userid=32274
View this thread: http://www.excelforum.com/showthread...hreadid=521940

  #7   Report Post  
Posted to microsoft.public.excel.misc
daddylonglegs
 
Posts: n/a
Default Count number of cells of a particular month in a column of dates


If you don't care about the year you could use

=SUMPRODUCT(--(MONTH(D2:D15)=3))

where 3 = March

be careful if you try to count for January because blank cells will be
included in the count so you need to alter to

=SUMPRODUCT(--ISNUMBER(D2:D15),--(MONTH(D2:D15)=1))


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
View this thread: http://www.excelforum.com/showthread...hreadid=521940

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
Count if date is between two dates and value in another column equ mg_sv_r Excel Worksheet Functions 2 December 6th 05 02:31 PM
How to count the number of times something occurs within a certain month Joyce Excel Worksheet Functions 2 October 18th 05 08:38 PM
Count cells based on date range in another column [email protected] New Users to Excel 1 May 5th 05 08:11 PM
How do I count cells in a column of dates between date ranges? Andrew82 Excel Worksheet Functions 2 April 14th 05 09:59 AM
GET.CELL Biff Excel Worksheet Functions 2 November 24th 04 07:16 PM


All times are GMT +1. The time now is 12:37 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"