NETWORKDAYS.INTL Function


The Excel NETWORKDAYS.INTL function calculates the number of working days between two dates. NETWORKDAYS.INTL excludes Saturday and Sunday by default, but provides a way to specify which days of the week are considered weekends.  The function can optionally exclude a list of holidays supplied as dates.


Syntax

The syntax for the NETWORKDAYS.INTL function in Microsoft Excel is:

=NETWORKDAYS.INTL( start_date, end_date, [weekend], [holidays] )

Parameters or Arguments

start_date

The start date to use in the calculation. It must be entered using the DATE function.

end_date

The end date to use in the calculation. It must be entered using the DATE function.

weekend

Optional. It is the days of the week to include as weekend days. If this parameter is omitted, it will assume that weekends include Saturday and Sunday. The weekend parameter can be one of the following numeric or string values:
Value
Explanation(days of week to include as weekend days)
1
Saturday and Sunday (default)
2
Sunday and Monday
3
Monday and Tuesday
4
Tuesday and Wednesday
5
Wednesday and Thursday
6
Thursday and Friday
7
Friday and Saturday
11
Sunday
12
Monday
13
Tuesday
14
Wednesday
15
Thursday
16
Friday
17
Saturday

holidays

Optional. It is the list of holidays to exclude from the work days calculation. It can be entered either as a range of cells that contain the holiday dates (ie: E2:E4) or as a list of serial numbers that represent the holiday dates.

Networkdays.Intl Function Examples


The spreadsheets below show three examples of the Excel Networkdays.Intl function used to calculate the number of work days between the two dates Dec 01, 2015 and Jan 15, 2016. In each case, the days to be counted as weekends and holidays are different.

Formulas:


A
B
C
1
Start Date:
12/01/2015

2
End Date:
01/15/2016

3
Holidays:
12/25/2015

4

12/28/2015

5

01/01/2016

6



7
Work days between Dec 1st, 2015 & Jan 15th, 2016:
8
=NETWORKDAYS.INTL( B1, B2 )
- Weekends Sat & Sun; No holidays
9
=NETWORKDAYS.INTL( B1, B2, 1, B3:B5 )
- Weekends Sat & Sun; Excludes holidays in cells B3-B5
10
=NETWORKDAYS.INTL( B1, B2, "0000111" )
- Weekends Fri, Sat & Sun; No holidays

Results:


A
B
C
7
Work days between Dec 1st, 2015 & Jan 15th, 2016:
8
34

- Weekends Sat & Sun; No holidays
9
31

- Weekends Sat & Sun; Excludes holidays in cells B3-B5
10
27

- Weekends Fri, Sat & Sun; No holidays

Note that, in the above spreadsheets:

   The [holidays] array has been omitted from the calculation in cell A8. Therefore, this result excludes Saturdays and Sundays but includes all other weekdays, including the holidays at Christmas and New Year.
   In cell A9 of the example spreadsheet, the [weekend] argument is 1 (specifying weekends on Saturdays and Sundays) and the [holidays] array (in cells B3-B5) is provided to the Networkdays.Intl function. Therefore, the calculation excludes Saturdays and Sundays and the listed Christmas and New Year holidays.
   In the example in cell A10, Fridays, Saturdays and Sundays are specified as weekends, but no holiday array has been supplied to the function. Therefore, the calculation excludes Fridays, Saturdays and Sundays but includes all other weekdays, including the holidays at Christmas and New Year.
Note also that, as recommended by Microsoft, in all three calls to the Networkdays.Intl function, the start_date, end_date, and [holidays] arguments have been supplied as cell references.

References


Networkdays() Function


The Excel NETWORKDAYS function calculates the number of working days between two dates. NETWORKDAYS automatically excludes weekends (Saturday and Sunday) and can optionally exclude a list of holidays supplied as dates. If you need more flexibility, use the NETWORKDAYS.INTL function.


Syntax

The syntax for the NETWORKDAYS function in Microsoft Excel is:

=NETWORKDAYS( start_date, end_date, [holidays] )

Parameters or Arguments

start_date

The start date to use in the calculation and should be entered as a serial date, not a text date.

end_date

The end date to use in the calculation and should be entered as a serial date, not a text date.

holidays

Optional. It is the list of holidays to exclude from the work days calculation. It can be entered either as a range of cells that contain the holiday dates (ie: F2:F5) or as a list of serial numbers that represent the holiday dates.

Networkdays Function Examples

The spreadsheet below provides two examples of the Excel Networkdays function, used to calculate the number of work days between the two dates Dec 01, 2015 and Jan 15, 2016.
One of the examples (in cell A8) ignores holidays (other than weekends), while the second example (in cell A9) provides a list of holidays to be excluded from the day count in the calculation.

Formulas:


A
B
C
1
Start Date:
12/01/2015

2
End Date:
01/15/2016

3
Holidays:
12/25/2015

4

12/28/2015

5

01/01/2016

6



7
Work days between Dec 1st, 2015 & Jan 15th, 2016:
8
=NETWORKDAYS( B1, B2 )
- No Holidays
9
=NETWORKDAYS( B1, B2, B3:B5 )
- Excludes holidays in cells B3-B5

Results:


A
B
C
7
Work days between Dec 1st, 2015 & Jan 15th, 2016:
8
34

- No Holidays
9
31

- Excludes holidays in cells B3-B5

In the above spreadsheet:

   The [holidays] array has been omitted from the calculation in cell A8. Therefore this result excludes Saturdays and Sundays but includes all other weekdays, including the holidays at Christmas and New Year.
   In the example in cell A9, the [holidays] array (in cells B3 - B5) is provided to the Networkdays function. Therefore the calculation excludes Saturdays and Sundays and the listed Christmas and New Year holidays.

References


Data Validation (Session2) – Numbers, Date and Text

Data validation is a feature in Excel used to control what a user can enter into a cell.  It can also stop invalid user input.
Data validation can be used to present the user with a predefined choice in a dropdown menu. This can be a convenient way to give a user exactly the values that meet requirements.
When adding a data validation rule in Excel, you can choose one of the predefined settings or specify custom criteria based on your own validation formula.

Whole numbers and decimals

To restrict data entry to a whole number or decimal, select the corresponding item in the Allowbox. And then, choose one of the following criteria in the Data box:
·         Equal to or not equal to the specified number
·         Greater than or less than the specified number
·         Between the two numbers or not between to exclude that range of numbers
For example, this is how you create an Excel validation rule that allows any whole number greater than 0:


Date and time validation in Excel

To validate dates, select Date in the Allow box, and then pick an appropriate criterion in the Data box. There are quite a lot of predefined options to choose from: allow only dates between two dates, equal to, greater than or less than a specific date, and more.
Similarly, to validate times, select Time in the Allow box, and then define the required criteria.
For example, to allow only dates between Start date in B1 and End date in B2, apply this Excel date validation rule:

Text length

To allow data entry of a specific length, select Text length in the Allow box, and choose the validation criteria in accordance with your business logic.
For example, to limit the input to 10 characters, create this rule:

Note. The Text length option limits the number of characters but not the data type, meaning the above rule will allow both text and numbers under 10 characters or 10 digits, respectively.

Limitation

It is important to understand that data validation can be easily defeated. If a user copies data from a cell without validation to a cell with data validation, the validation is destroyed (or replaced). Data validation is a good way to let users know what is allowed or expected, but it is not a foolproof way to guarantee input.

References


Combination Functions – Combina()

Combin and Combina Functions

The Excel Combin and CombinA functions both calculate a number of combinations of a set of objects.
However, the two functions differ in that the Combin function does not count repetitions whereas the CombinA function does count repetitions.
For example, in a set of 3 objects, a, b, c, how many combinations of 2 objects are there?
The Combin function returns the result 3 (combinations: ab, ac, bc);
The Combina function returns the result 6 (combinations: aa, ab, ac, bb, bc, cc).

CombinA() Function

The Excel Combina function calculates the number of combinations, with repetitions, of a given number objects from a set.


Syntax

The syntax for the COMBINA function in Microsoft Excel is:

=COMBINA( number, chosen )

Parameters or Arguments

number

The number of items represented as an integer. It can not be a negative value and it must be greater than or equal to chosen. If a non-integer value is entered for this parameter, it will truncate the value.

chosen

The number of items in a combination. It can not be a negative value. If a non-integer value is entered for this parameter, it will truncate the value.

Excel Combina Function Examples

For any 6 objects (e.g. a, b, c, d, e, f), there are 21 different combinations (with repetitions) of 2 objects. These are:

aa
ab
ac
ad
ae
af
bb
bc
bd
be
bf
cc
cd
ce
cf
dd
de
df
ee
ef
ff

This calculation is shown in cell A2 of the following example spreadsheet.
The example spreadsheet below also shows the Combina function used to calculate the number of combinations (with repetitions) for other numbers of objects taken from a set of 6.

Formulas:


A
1
=COMBINA( 6, 1 )
2
=COMBINA( 6, 2 )
3
=COMBINA( 6, 3 )
4
=COMBINA( 6, 4 )
5
=COMBINA( 6, 5 )
6
=COMBINA( 6, 6 )

Results:


A
1
6
2
21
3
56
4
126
5
252
6
462

Notes

   The COMBINA function was only introduced in Excel 2013 and so is not available in earlier versions of Excel.
   Arguments that contain decimal values are truncated to integers.
   COMBINA returns a #VALUE! error value if either argument is not numeric.
   If number is less than number chosen, COMBINA returns #NUM!

References

like us on https://www.facebook.com/Arivilm2501

OR Function