Professional Documents
Culture Documents
DAY Function:
Description:
The Microsoft Excel DAY function returns the day of the month (a
number from 1 to 31) given a date value. The DAY function is a built-in
function in Excel that is categorized as a Date/Time Function. It can be
used as a worksheet function (WS) in Excel. As a worksheet function, the
DAY function can be entered as part of a formula in a cell of a worksheet.
A valid date to return the day of the month.
Syntax:
The syntax for the DAY function in Microsoft Excel is: DAY(
date_value )
Returns:
The DAY function returns a numeric value between 1 and 31.
1. =DAY(A1) Result: 1
Tarjani
3. =DAY(A3) Result: 15
4. =DAY("12/31/2011") Result: 31
MONTH Function:
Description:
The Microsoft Excel MONTH function returns the month (a number from
1 to 12) given a date value. The MONTH function is a built-in function in
Excel that is categorized as a Date/Time Function. It can be used as a
worksheet function (WS) As a worksheet function, the MONTH function
can be entered as part of a formula in a cell of a worksheet. A valid date
to return the month.
Syntax:
The syntax for the MONTH function in Microsoft Excel is: MONTH(
date_value )
Returns:
The MONTH function returns a numeric value between 1 and 12.
Tarjani
1. =MONTH(B2) Result: 9
2. =MONTH(B3) Result: 8
3. =MONTH(B4) Result: 4
4. =MONTH("12/31/2011") Result: 12
YEAR Function:
Description:
The Microsoft Excel YEAR function returns a four-digit year (a number
from 1900 to 9999) given a date value. The YEAR function is a built-in
function in Excel that is categorized as a Date/Time Function. It can be
used as a worksheet function (WS) in Excel. As a worksheet function, the
YEAR function can be entered as part of a formula in a cell of a
worksheet. A valid date to return the year value.
Syntax:
The syntax for the YEAR function in Microsoft Excel is: YEAR(
date_value )
Returns:
The YEAR function returns a numeric value between 1900 and 9999.
Tarjani
NOW Function:
Description:
The Microsoft Excel NOW function returns the current system date and
time. The NOW function is a built-in function in Excel that is categorized
as a Date/Time Function. It can be used as a worksheet function (WS) in
Excel. As a worksheet function, the NOW function can be entered as part
of a formula in a cell of a worksheet. As a VBA function, you can use this
function in macro code that is entered through the Microsoft Visual Basic
Editor. When used as a worksheet function, the NOW function will
refresh the date/time value whenever the worksheet recalculates. There
are no parameters or arguments for the NOW function.
Syntax:
The syntax for the NOW function in Microsoft Excel is: NOW()
Returns:
The NOW function returns a date value.
Tarjani
The spreadsheet will continue to display this value, until the worksheet
recalculates. By pressing the F9 key, you can force the worksheet to
recalculate and the NOW function will update its value.
SECOND Function:
Description:
The Microsoft Excel SECOND function returns the seconds (a number
from 0 to 59) from a time value. The SECOND function is a built-in
function in Excel that is categorized as a Date/Time Function. It can be
used as a worksheet function (WS) in Excel. As a worksheet function, the
SECOND function can be entered as part of a formula in a cell of a
worksheet. The time value to extract the second from. It may be
expressed as a string value, a decimal number, or the result of a formula.
Syntax:
The syntax for the SECOND function in Microsoft Excel is: SECOND(
serial_number )
Returns:
The SECOND function returns a numeric value between 0 and 59.
Tarjani
1. =SECOND(A1) Result: 35
2. =SECOND(A2) Result: 0
MINUTE Function:
Description:
The Microsoft Excel MINUTE function returns the minutes (a number
from 0 to 59) from a time value. The MINUTE function is a built-in
function in Excel that is categorized as a Date/Time Function. It can be
used as a worksheet function (WS) in Excel. As a worksheet function, the
MINUTE function can be entered as part of a formula in a cell of a
worksheet. The time value to extract the minutes from. It may be
expressed as a string value, a decimal number, or the result of a formula.
Tarjani
Syntax:
The syntax for the MINUTE function in Microsoft Excel is: MINUTE(
serial_number )
Returns:
The MINUTE function returns a numeric value between 0 and 59.
1. =MINUTE(A2) Result: 10
2. =MINUTE(A3) Result: 55
3. =MINUTE(A4) Result: 45
4. =MINUTE(A5) Result: 30
Tarjani
HOUR Function:
Description:
The Microsoft Excel HOUR function returns the hours (a number from 0
to 23) from a time value. The HOUR function is a built-in function in
Excel that is categorized as a Date/Time Function. It can be used as a
worksheet function (WS) in Excel. As a worksheet function, the HOUR
function can be entered as part of a formula in a cell of a worksheet. The
time value to extract the hour from. It may be expressed as a string value,
a decimal number, or the result of a formula.
Syntax:
The syntax for the HOUR function in Microsoft Excel is: Hour(
serial_number )
Returns:
The HOUR function returns a numeric value between 0 and 23.
1. =HOUR(A1) Result: 13
2. =HOUR(A2) Result: 7
Tarjani
Today function:
Description:
he Microsoft Excel TODAY function returns the current system date. This
function will refresh the date whenever the worksheet recalculates. The
TODAY function is a built-in function in Excel that is categorized as a
Date/Time Function. It can be used as a worksheet function (WS) in Excel. As a
worksheet function, the TODAY function can be entered as part of a formula in
a cell of a worksheet. There are no parameters or arguments for the TODAY
function.
Syntax:
The syntax for the TODAY function in Microsoft Excel is: TODAY()
Returns:
The TODAY function returns a serial date value. A serial date is how
Excel stores dates internally and it represents the number of days since
January 1, 1900.
Tarjani
EDATE Function:
Description:
The Microsoft Excel EDATE function adds a specified number of months to a
date and returns the result as a serial date. The EDATE function is a built-in
function in Excel that is categorized as a Date/Time Function. It can be used as
a worksheet function (WS) in Excel. As a worksheet function, the EDATE
function can be entered as part of a formula in a cell of a worksheet. start_date:
The starting date to use in the calculation. Months : The number of months to
add to the start_date. It can be a positive or negative value.
Syntax:
The syntax for the EDATE function in Microsoft Excel is: EDATE(
start_date, months )
Returns:
The EDATE function returns a serial date value. A serial date is how
Excel stores dates internally and it represents the number of days since
January 1, 1900.
If start_date is not a valid date, the EDATE function will return the
#VALUE! error.
Tarjani
The result of the EDATE function is a serial date and can be seen in
column C above.
Most often you will want a formatted date rather than a serial date.
Column D demonstrates the serial date returned by the EDATE
function that has been formatted using mmm d, yyyy.
1. =EDATE(A2,B2)
Result: 42426 'Which can be formatted as "Feb 26, 2016"
2. =EDATE(A3,B3)
Result: 42475 'Which can be formatted as "Apr 15, 2016"
3. =EDATE(A4,B4)
Result: 42617 'Which can be formatted as "Sep 4, 2016"
4. =EDATE(A5,B5)
Result: 42520 'Which can be formatted as "May 30, 2016"
5. =EDATE("1/27/2016",3)
Result: 42487 'Which can be formatted as "Apr 27, 2016"
WORKDAY Function
Description:
The Microsoft Excel WORKDAY function adds a specified number of work
days to a date and returns the result as a serial date. Weekends are not
considered work days and you can specify holidays to also exclude from the
Tarjani
Syntax:
The syntax for the WORKDAY function in Microsoft Excel is:
WORKDAY( start_date, days, [holidays] )
Returns:
The WORKDAY function returns a serial date value. A serial date is how
Excel stores dates internally and it represents the number of days since
January 1, 1900.
Note
1. Weekends are defined as Saturday and Sunday. If you want to use
different days as the weekend, try the WORKDAY.INTL function.
3. If you enter a range of cells for the holidays, enter the range as an
absolute value so that the range does not change when copying the
formula to different cells. For example, if your holidays are stored in
the range G2:G5, it is best to enter the range as $G$2:$G$5.
Tarjani
The result of the WORKDAY function is a serial date and can be seen in
column C above.
Most often you will want a formatted date rather than a serial date.
Column D demonstrates the serial date returned by the WORKDAY
function that has been formatted using mmm d, yyyy.
1. =WORKDAY(A2,B2,$G$2:$G$5)
Result: 42369 'Which can be formatted as "Dec 31, 2015"
2. =WORKDAY(A3,B3,$G$2:$G$5)
Result: 42373 'Which can be formatted as "Jan 4, 2016"
3. =WORKDAY(A4,B4,$G$2:$G$5)
Result: 42458 'Which can be formatted as "Mar 29, 2016"
4. =WORKDAY(A5,B5,$G$2:$G$5)
Result: 42464 'Which can be formatted as "Apr 4, 2016"
For example, here is how you would enter a single date as a holiday:
Tarjani
If you want to enter more than one holiday as a text date, you will need to enter
the dates as an array. For example:
1. =WORKDAY(A5,B5,{"1/1/2016","3/25/2016","3/28/2016","12/25/2016
"}) Result: 42464 'Which can be formatted as "Apr 4, 2016"
1. =WORKDAY(A2,B2,42370)
Result: 42369 'Which can be formatted as "Dec 31, 2015"
Since 42370 is the serial date for Jan 1, 2016, that date will be excluded from
the work day calculation.
If you want to enter more than one holiday as a serial date, you need to include
your serial dates as an array. For example:
1. =WORKDAY(A5,B5,{42370,42454,42457,42729})
Result: 42464 'Which can be formatted as "Apr 4, 2016"
Since 42370 is 1/1/2016, 42454 is 3/25/2016, 42457 is 3/28/2016 and 42729 is
12/25/2016, these dates will not be included as work days.
TIP: To see the numeric value for any serial date, change the format of the cell
to General. It will then display the serial date value.
WORKDAY.INTL Function:
Description:
The Microsoft Excel WORKDAY.INTL function adds a specified number of
work days to a date and returns the result as a serial date. Weekends are
customizable and are not considered work days. You can also specify holidays
to exclude from the work day calculation. The WORKDAY.INTL function is a
built-in function in Excel that is categorized as a Date/Time Function. It can be
used as a worksheet function (WS) in Excel. As a worksheet function, the
Tarjani
Days
The number of work days added to start_date.
Weekend
Optional. It determines which days of the week are considered weekends. It can
be one of the following values:
Value Explanation
1 (default) The weekend is Saturday and Sunday
2 The weekend is Sunday and Monday
3 The weekend is Monday and Tuesday
4 The weekend is Tuesday and Wednesday
5 The weekend is Wednesday and Thursday
6 The weekend is Thursday and Friday
7 The weekend is Friday and Saturday
11 The weekend is only Sunday
12 The weekend is only Monday
13 The weekend is only Tuesday
14 The weekend is only Wednesday
15 The w eekend is only Thursday
16 The weekend is only Friday
17 The weekend is only Saturday
Holidays
Optional. It is the list of holidays to exclude as work days from the calculation.
It can be entered either as a range of cells that contain the holiday dates (ie:
G3:G6) or as a list of serial numbers that represent the holiday dates.
Tarjani
Syntax:
The syntax for the WORKDAY.INTL function in Microsoft Excel is:
WORKDAY.INTL( start_date, days, [weekend], [holidays] )
Returns:
The WORKDAY.INTL function returns a serial date value. A serial date
is how Excel stores dates internally and it represents the number of days
since January 1, 1900.
Note
If a decimal value is provided for days, the WORKDAY.INTL
function will only add the integer portion to start_date.
If you enter a range of cells for the holidays, enter the range as an
absolute value so that the range does not change when copying
the formula to different cells. For example, if your holidays are
stored in the range G3:G6, it is best to enter the range as
$G$3:$G$6.
A serial date is how Excel stores dates internally and it represents
the number of days since January 1, 1900.
The result of the WORKDAY.INTL function is a serial date and can be seen in
column C above. Most often you will want a formatted date rather than a serial
date. Column D demonstrates the serial date returned by the WORKDAY.INTL
function that has been formatted using mmm d, yyyy.
Tarjani
1. =WORKDAY.INTL(A3,B3,1,$G$3:$G$6)
Result: 42369 'Which can be formatted as "Dec 31, 2015"
2. =WORKDAY.INTL(A4,B4,1,$G$3:$G$6)
Result: 42373 'Which can be formatted as "Jan 4, 2016"
3. =WORKDAY.INTL(A5,B5,1,$G$3:$G$6)
Result: 42458 'Which can be formatted as "Mar 29, 2016"
4. =WORKDAY.INTL(A6,B6,1,$G$3:$G$6)
Result: 42464 'Which can be formatted as "Apr 4, 2016"
1. =WORKDAY.INTL(A3,B3,1,"1/1/2016")
Result: 42369 'Which can be formatted as "Dec 31, 2015"
This formula would treat Jan 1, 2016 as a holiday and exclude it from the work
day calculation. If you want to enter more than one holiday as a text date, you
will need to enter the dates as an array.
For example:
1. =WORKDAY.INTL(A6,B6,1,{"1/1/2016","3/25/2016","3/28/2016","12/
25/2016"})
Result: 42464 'Which can be formatted as "Apr 4, 2016"
Tarjani
Syntax:
The syntax for the DATEVALUE function in Microsoft Excel is:
DATEVALUE( date )
Returns:
The DATEVALUE function returns a date value when used as a VBA
function and it returns a serial date when used as a worksheet function. A
serial date is how Excel stores dates internally and it represents the
number of days since January 1, 1900.
Tarjani
Tarjani