WorksheetFunction.NetworkDays_Intl Method (Excel)
Returns the number of whole workdays between two dates using parameters to indicate which and how many days are weekend days. Weekend days and any days that are specified as holidays are not considered as workdays.
Version Information
Version Added: Excel 2010
Syntax
expression .NetworkDays_Intl(Arg1, Arg2, Arg3, Arg4)
expression A variable that represents a WorksheetFunction object.
Parameters
Name |
Required/Optional |
Data Type |
Description |
---|---|---|---|
Arg1 |
Required |
Variant |
Start_date - The start date for which the difference is to be computed. The start_date can be earlier than, the same as, or later than the end_date. |
Arg2 |
Required |
Variant |
End_date - The end date for which the difference is to be computed. The start_date can be earlier than, the same as, or later than the end_date. |
Arg3 |
Optional |
Variant |
Weekend - Indicates the days of the week that are weekend days and are not included in the number of whole working days between start_date and end_date. Weekend is a weekend number or string that specifies when weekends occur. Weekend number values indicate the weekend days listed in the following table.
Weekend number Weekend days
1 or omitted Saturday, Sunday
2 Sunday, Monday
3 Monday, Tuesday
4 Tuesday, Wednesday
5 Wednesday, Thursday
6 Thursday, Friday
7 Friday, Saturday
11 Sunday only
12 Monday only
13 Tuesday only
14 Wednesday only
15 Thursday only
16 Friday only
17 Saturday only
|
Arg4 |
Optional |
Variant |
Holidays - An optional set of one or more dates that are to be excluded from the working day calendar. Holidays is a range of cells that contain the dates, or an array constant of the serial values that represent those dates. The ordering of dates or serial values in holidays can be arbitrary. |
Return Value
Double
Remarks
If start_date is later than end_date, the return value will be negative, and the magnitude will be the number of whole workdays.
If start_date is out of range for the current date base value, NETWORKDAYS_INTL returns the #NUM! error value.
If end_date is out of range for the current date base value, NETWORKDAYS_INTL returns the #NUM! error value.
If a weekend string is of invalid length or contains invalid characters, NETWORKDAYS_INTL returns the #VALUE! error value.