View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
T. Valko T. Valko is offline
external usenet poster
 
Posts: 15,768
Default Number of dates falling in a date range

As long as *all* of your dates are true Excel dates. Try this:

A1 = start date
B1 = end date

Sheet2 A1:A3 = exception dates

=COUNTIF(Sheet2!A1:A3,"="&A1)-COUNTIF(Sheet2!A1:A3,""&B1)

--
Biff
Microsoft Excel MVP


"Cralis" wrote in message
...
Hi guys,

I'm pretty new to Excel, but am trying to do something.

I know about NETWORKDAYS. The query I have is different, I think.

I have a cell holding Start Date, and a cell holding End Date.

On another sheet, I have a column holding specific dates. For example,
public holidays.

Is there a way to get the number of these public holidays that fall
within my start/end date?

For example:

Start Date: 1st Jan, 2009
End Date: 10th Jan, 2009

Exception Dates:
4th Jan
8th Jan
12th Jan

Based on that data, I need to report '2' as the answer, as 4th and 8th
fall inside my range. Is there a formula or something I can use to
calculate this?