• Microsoft Office
  • Microsoft Windows
  • Other Software
  • Anti Virus
  • Blog
    • Word
    • Excel
    • Powerpoint
    • Software tricks/tips
  • POLICIES
    • PAYMENT GUIDE
    • SHIPPING POLICY
    • REFUND POLICY
    • TERMS & CONDITIONS
    • Contact Us

No products in the cart.

  • Microsoft Office
  • Microsoft Windows
  • Other Software
  • Anti Virus
  • Blog
    • Word
    • Excel
    • Powerpoint
    • Software tricks/tips
  • POLICIES
    • PAYMENT GUIDE
    • SHIPPING POLICY
    • REFUND POLICY
    • TERMS & CONDITIONS
    • Contact Us

No products in the cart.

  • Microsoft Office
  • Microsoft Windows
  • Other Software
  • Anti Virus
  • Blog
    • Word
    • Excel
    • Powerpoint
    • Software tricks/tips
  • POLICIES
    • PAYMENT GUIDE
    • SHIPPING POLICY
    • REFUND POLICY
    • TERMS & CONDITIONS
    • Contact Us

No products in the cart.

  • Microsoft Office
  • Microsoft Windows
  • Other Software
  • Anti Virus
  • Blog
    • Word
    • Excel
    • Powerpoint
    • Software tricks/tips
  • POLICIES
    • PAYMENT GUIDE
    • SHIPPING POLICY
    • REFUND POLICY
    • TERMS & CONDITIONS
    • Contact Us
Excel

How to use the DATEDIF function to calculate the time interval between two dates in Excel

0 Comments

How to use the DATEDIF function to calculate the time interval between two dates in Excel: Excel provides users with many functions to calculate dates and times. In this article, Buffcom.net will introduce how to use the DATEDIF function to calculate the time between two dates in Excel.

1. DATEDIF function structure

Function syntax: =DATEDIF(start_date, end_date, unit)
Where:

  • Start_date: required argument, is the first date or start date of a time period.
  • End_date: required argument, is the first date or end date of a time period.
  • Unit: required argument, is the type of information you want to return.

Types of Unit argument:

  • Y: Number of completed years in the time period.
  • M: Number of completed months in the time period.
  • D: Number of days in the time period.
  • MD: Number of days between the days in start_date and end_date. Ignore the month and year.
  • YM: Number of months between the months in start_date and end_date. Ignore the day and year.
  • Yd: Number of days between the days in start_date and end_date. Ignore the year.

Note: If start_date is greater than end_date, the function will return the #NUM! error.

2. How to use the DATEDIF function

For example, we need to calculate the time period between two dates, 4/5/2015 and 11/12/2019, using different Unit arguments as shown in the image below.

How to use the DATEDIF function to calculate the time interval between two dates in Excel

How to use the DATEDIF function to calculate the time interval between two dates in Excel

As we can see, the function will calculate differently depending on the Unit argument:

  • Y: Number of years between the two dates 4/5/2015 and 11/12/2019.
  • M: Number of months between the two dates 4/5/2015 and 11/12/2019.
  • D: Number of days between the two dates 4/5/2015 and 11/12/2019.
  • MD: Number of days between the days 4 and 11.
  • YM: Number of months between the months 5 and 12.
  • Yd: Number of days between the two dates 4/5 and 11/12.

Therefore, this article has instructed you on how to use the DATEDIF function in Excel. Wish you success!

3
47 Views
How to use INDIRECT function to create a reference range in ExcelPrevHow to use INDIRECT function to create a reference range in ExcelApril 25, 2023
How to Quickly and Conveniently Recover an Unsaved FileApril 25, 2023How to Quickly and Conveniently Recover an Unsaved FileNext

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Recent Posts
  • Retrieve Data Based on Data Validation
    September 7, 2023
    Excel
  • How to Convert Multiple Rows to Columns and Rows in Excel?
    September 6, 2023
    Excel
  • VLOOKUP for Automatic Discount in Data Validation
    September 6, 2023
    Excel
  • How to Convert Text Dates to Dates in Excel?
    September 5, 2023
    Excel
Categories
  • Blog 80
  • Excel 754
  • Powerpoint 36
  • Software tricks/tips 128
  • Uncategorized 8
  • Word 109
Tags
the ISERROR
Top rated products
  • Kaspersky Small Office Security 15 PCs + 15 Mobiles + 2 Servers 1 Year Kaspersky Small Office Security 15 PCs + 15 Mobiles + 2 Servers 1 Year
    Rated 5.00 out of 5
    $201.00
  • Buy Windows 11 Professional MS Products CD Key
    Rated 5.00 out of 5
    $11.00
  • AVG Internet Security 2021 1 Device 1 Year Global AVG Internet Security 2021 1 Device 1 Year Global
    Rated 5.00 out of 5
    $11.00
  • Buy Office 2021 Professional Plus Key Global For 5 PC
    Rated 5.00 out of 5
    $45.00
  • Avast SecureLine VPN 2021 2 Years 5 Devices Global Avast SecureLine VPN 2021 2 Years 5 Devices Global
    Rated 5.00 out of 5
    $47.00
Products
  • Buy Office 2021 Professional Plus Key Global For 5 PC
    Rated 5.00 out of 5
    $45.00
  • Buy Office 2021 Professional Plus Key Global Bind To Your Microsoft Account
    Rated 4.83 out of 5
    $49.00
  • Windows Server 2022 Datacenter Key Global
    Rated 5.00 out of 5
    $15.00
  • Windows Server 2022 Standard Key Global
    Rated 4.47 out of 5
    $15.00
  • Windows Server 2022 Remote Desktop Services Device Connections (50) Cal Key Global
    Rated 5.00 out of 5
    $45.00

Buffcom.net always brings the best digital products and services to you. Specializing in Office Software and online marketing services

BIG SALE 50% IN MAY

Microsoft Office
Microsoft Windows
Anti-Virus
Contact Us

Visit Us:

125 Division St, New York, NY 10002, USA

Mail Us:

buffcom.net@gmail.com

TERMS & CONDITIONS | PAYMENT GUIDE  | SHIPPING POLICY  | REFUND POLICY

Copyright © 2019 buffcom.net  All Rights Reserved.