ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Countif Function for dates in a range (https://www.excelbanter.com/excel-worksheet-functions/155394-countif-function-dates-range.html)

Mbanker

Countif Function for dates in a range
 
I want to count a range of data if a cell in a range is within a date range.
I n others, If column D is a range of dates for a 12 month period, how can I
count the # of dates tthat are in the date range 8-1-2007 through 8-31-2007?

Max

Countif Function for dates in a range
 
Try in say, E1:
=SUMPRODUCT(--(TEXT(D2:D100,"mmmyy")="Aug07"))
Adapt the range to suit
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Mbanker" wrote:
I want to count a range of data if a cell in a range is within a date range.
I n others, If column D is a range of dates for a 12 month period, how can I
count the # of dates tthat are in the date range 8-1-2007 through 8-31-2007?


Ron Rosenfeld

Countif Function for dates in a range
 
On Wed, 22 Aug 2007 14:28:00 -0700, Mbanker
wrote:

I want to count a range of data if a cell in a range is within a date range.
I n others, If column D is a range of dates for a 12 month period, how can I
count the # of dates tthat are in the date range 8-1-2007 through 8-31-2007?


=countif(d:d,"="&date(2007,8,1)) -
countif(d:d,""&date(2007,8,31))


--ron


All times are GMT +1. The time now is 02:53 PM.

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