Skip to content
Practical – 125 : Any 5 Date Related Function with Example in Excel..

- DATEDIF:Â
- Calculates the difference between two dates (start date and end date) in days, months, or years.
- Syntax:Â =DATEDIF(start_date, end_date, unit)
- unit can be “d” for days, “m” for months, or “y” for years.
- Example: To calculate the number of years between two dates, you would use =DATEDIF(start_date, end_date, “y”).
- EDATE:Â
- Returns a date that is a specified number of months before or after a given start date.
- Syntax:Â =EDATE(start_date, months)
- months is the number of months to add or subtract from the start_date.
- Example: To find the date 6 months after a given date, you would use =EDATE(start_date, 6).
- EOMONTH:Â
- Returns the last day of the month before or after a specified number of months from a given date.
- Syntax:Â =EOMONTH(start_date, months)
- months is the number of months to add or subtract from the start_date.
- Example: To find the last day of the current month, you would use =EOMONTH(TODAY(), 0).
- NETWORKDAYS:Â
- Calculates the number of workdays (excluding weekends and holidays) between two dates.
- Syntax:Â =NETWORKDAYS(start_date, end_date, [holidays])
- [holidays]Â is an optional argument that can be used to specify a range of cells containing holidays to be excluded from the calculation.
- Example: To calculate the number of workdays between two dates, you would use =NETWORKDAYS(start_date, end_date).
- WORKDAY:Â
- Returns a date that is a specified number of workdays before or after a given start date.
- Syntax:Â =WORKDAY(start_date, days, [holidays])
- days is the number of workdays to add or subtract from the start_date.
- [holidays]Â is an optional argument that can be used to specify a range of cells containing holidays to be excluded from the calculation.
- Example: To find a date 5 workdays after a given date, you would use =WORKDAY(start_date, 5).
- DATEVALUE:Â
- Converts a date in text format to a serial number that Excel can use for calculations.
- Syntax:Â =DATEVALUE(date_text)
- date_text is a text string representing the date.
- Example: To convert a date in text format (e.g., “12/25/2023”) to a serial number, you would use =DATEVALUE(“12/25/2023”)