Excel NETWORKDAYS Function

This Excel Tutorial demonstrates how to use the Excel NETWORKDAYS Function in Excel to get the number of business days between dates, with formula examples.

NETWORKDAYS Function Description:

The NETWORKDAYS Function Returns the number of working days between two dates. Working days include Mon-Fri and exclude Sat-Sun. Optionally, you can exclude holidays.

Formula Examples:

networkdays function examples

ExampleFormulaResult
Positive=NETWORKDAYS(C5,D5)45
Negative=NETWORKDAYS(C6,D6)-45
Include Holidays=NETWORKDAYS(C7,D7,F5:F7)42

Syntax and Arguments:

The Syntax for the NETWORKDAYS Formula is:

Function Arguments ( Inputs ):

start_date – The start date in Excel serial number format or entered as a date with quotations (“s) surround the date. Example: You can not enter 11/12/2015 directly into the cell. Instead you need to enter “11/12/2015” or you would need to use the corresponding serial number: 42320. Alternatively, you can reference a cell with the date 11/12/2015 entered. Excel automatically converts dates stored in cells into serial format (unless the date is entered as text).

end_date – The end date in Excel serial number format or entered as a date with quotations (“s) surround the date. Example: You can not enter 11/12/2015 directly into the cell. Instead you need to enter “11/12/2015” or you would need to use the corresponding serial number: 42320. Alternatively, you can reference a cell with the date 11/12/2015 entered. Excel automatically converts dates stored in cells into serial format (unless the date is entered as text).

holidays – OPTIONAL. List of holidays to exclude from the “work days”. It can be entered as a list of serial numbers corresponding to the holidays. Alternatively, it can reference a range of cells that contain the holiday dates. Example: 42005,42189,42363 or A1:A3, referencing cells that contain that contain dates: 1/1/2015, 7/4/2015, 12/25/2015.

Additional Notes

NETWORKDAYS counts the number of non-weekend days in the week. Optionally you can enter an array of holidays for NETWORKDAYS to exclude as well. You can enter the days manually into the formula, however, it’s much easier to create a list and simply reference the list of holidays to exclude.

NETWORKDAYS Examples in VBA

You can also use the NETWORKDAYS function in VBA. Type:
application.worksheetfunction.networkdays(start_date,end_date,holidays)
For the function arguments (start_date, etc.), you can either enter them directly into the function, or define variables to use instead.

Return to the List of all Functions in Excel

How to use the NETWORKDAYS Function in Excel:

To use the AND Excel Worksheet Function, type the following into a cell:
=AND(
After entering it in the cell, notice how the AND formula inputs appear below the cell:
networkdays formula syntax
You will need to enter these inputs into the function. The function inputs are covered in more detail in the next section. However, if you ever need more help with the function, after typing “=NETWORKDAYS(” into a cell, without leaving the cell, use the shortcut CTRL + A (A for Arguments) to open the “Insert Function Dialog Box” for detailed instructions:
how to use the networkdays function in excel

For more information about the NETWORKDAYS Formula visit the
Microsoft Website.

ADS GO HERE

Posted in