ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   COUNTIF criteria using date ranges? (https://www.excelbanter.com/excel-worksheet-functions/42556-countif-criteria-using-date-ranges.html)

Annie

COUNTIF criteria using date ranges?
 
How would I indicate that I want to count the number of dates fall
between Date A and Date B? I looked in the other message threads about
subtracting one COUNTIF from another, but I don't think it works for
dates.

Thank you,
Annie


Duke Carey

Put your test dates in a cell, then use COUNTIF like so

=COUNTIF(A5:A30,"<="&A1)-COUNTIF(A5:A30,"<="&A2)



"Annie" wrote:

How would I indicate that I want to count the number of dates fall
between Date A and Date B? I looked in the other message threads about
subtracting one COUNTIF from another, but I don't think it works for
dates.

Thank you,
Annie



Don Guillett

try
=sumproduct((rngaa1)*(rngA<b1))

--
Don Guillett
SalesAid Software

"Annie" wrote in message
oups.com...
How would I indicate that I want to count the number of dates fall
between Date A and Date B? I looked in the other message threads about
subtracting one COUNTIF from another, but I don't think it works for
dates.

Thank you,
Annie




Bob Phillips

This also works

=COUNTIF(P1:P10,"<01/03/2005")-COUNTIF(P1:P10,"<01/02/2005")

but make sure that you format the cell as general as it tends to try and
force date format.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Duke Carey" wrote in message
...
Put your test dates in a cell, then use COUNTIF like so

=COUNTIF(A5:A30,"<="&A1)-COUNTIF(A5:A30,"<="&A2)



"Annie" wrote:

How would I indicate that I want to count the number of dates fall
between Date A and Date B? I looked in the other message threads about
subtracting one COUNTIF from another, but I don't think it works for
dates.

Thank you,
Annie






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

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