1. Home
  2. Computing & Technology
  3. Spreadsheets

Count Days Between Two Dates in Excel
Excel 2007 NETWORKDAYS Function

By Ted French, About.com

Excel 2007 NETWORKDAYS Function

Excel 2007 NETWORKDAYS Function

© Ted French

The NETWORKDAYS function, one of Excel's Date and Time functions, can be used to count the number of working days between two dates. The function automatically removes weekend days from the total. Specific holidays can also be omitted.

The syntax for the NETWORKDAYS function is:

= NETWORKDAYS ( Start_date , End_date , Holidays )

Start_date - the start date of the chosen time period.

End_date - the end date of the chosen time period.

Holidays - can be used to exclude one or more dates from the total number of working days (optional).

Counting Days Between Two Dates Example

Note: For help with this example, see the image to the right.

  1. Enter the following data into the appropriate cell:

    D1 - Start:
    D2 - Finish:
    D3 - Holiday 1:
    D4 - Holiday 2:
    E1 - 7/7/2008
    E2 - 11/7/2008
    E3 - 9/8/2008
    E4 - 10/13/2008

    Note: If the dates in cells E1 to E4 do not appear correct, check to see that these cells are formatted for dates.

  2. Click on cell F1 - the location where the results will be displayed.

  3. Click on the Formulas tab.

  4. Choose Date and Time functions > NETWORKDAYS from the ribbon to bring up the function's dialog box.

  5. Click on the Start_date line in the dialog box.

  6. Click on cell E1 in the spreadsheet.

  7. Click on the End_date line in the dialog box.

  8. Click on cell E2 in the spreadsheet.

  9. Click on the Holidays line in the dialog box.

  10. Drag select cells E3 and E4 in the spreadsheet.

  11. Click OK in the dialog box.

  12. The number of working days - 88 appears in cell F1.

  13. There are 90 weekdays between the start and end dates. From this number the two holidays in cells E3 and E4 are subtracted to leave 88 working days.

  14. When you click on cell F1 the complete function
    = NETWORKDAYS ( E1 , E2 , E3 : E4 ) appears in the formula bar above the worksheet.

Related Articles
More Spreadsheets Quick Tips
Explore Spreadsheets
About.com Special Features

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

Easy ways to connect two computers for networking purposes. More >

  1. Home
  2. Computing & Technology
  3. Spreadsheets
  4. Excel Functions
  5. Date Functions
  6. Count Days in Excel - Count Days between Two Dates in Excel

©2009 About.com, a part of The New York Times Company.

All rights reserved.