Is there a formula that will determine the number of years, months and days that someone has been employed with an institution? If you know the person’s start date…what function can I use to determine this information.
![]() |
Patch reliability is unclear. Unless you have an immediate, pressing need to install a specific patch, don't do it. |
SIGN IN | Not a member? | REGISTER | PLUS MEMBERSHIP |
-
Excel Function Question (Excel 97)
Home » Forums » AskWoody support » Productivity software by function » MS Excel and spreadsheet help » Excel Function Question (Excel 97)
- This topic has 3 replies, 4 voices, and was last updated 22 years ago.
AuthorTopicWSmisharenu99
AskWoody LoungerJune 3, 2003 at 3:47 pm #388472Viewing 1 reply threadAuthorReplies-
WSBat17
AskWoody Lounger -
WSpieterse
AskWoody LoungerJune 4, 2003 at 5:13 am #682399If I remember correctly, datedif is missing from Xl97 Help. It is there in the XL2000 help file:
DATEDIF
See alsoCalculates the number of days, months, or years between two dates. This function is provided for compatibility with Lotus 1-2-3.
Syntax
DATEDIF(start_date,end_date,unit)
Start_date is a date that represents the first, or starting, date of the period. Dates may be entered as text strings within quotation marks (for example, “2001/1/30”), as serial numbers (for example, 36921, which represents January 30, 2001, if you’re using the 1900 date system), or as the results of other formulas or functions (for example, DATEVALUE(“2001/1/30”)). For more information about date serial numbers, see NOW.
End_date is a date that represents the last, or ending, date of the period.
Unit is the type of information you want returned.
Unit Returns
“Y” The number of complete years in the period.
“M” The number of complete months in the period.
“D” The number of days in the period.
“MD” The difference between the days in start_date and end_date. The months and years of the dates are ignored.
“YM” The difference between the months in start_date and end_date. The days and years of the dates are ignored.
“YD” The difference between the days of start_date and end_date. The years of the dates are ignored.Remarks
Microsoft Excel stores dates as sequential serial numbers so that it can perform calculations on them. Excel stores January 1, 1900, as serial number 1 if your workbook uses the 1900 date system. If your workbook uses the 1904 date system, Excel stores January 1, 1904, as serial number 0 (January 2, 1904, is serial number 1). For example, in the 1900 date system, Excel stores January 1, 1998, as serial number 35796 because it is 35,795 days after January 1, 1900. Learn more about how Microsoft Excel stores dates and times.
Excel for Windows and Excel for the Macintosh use different date systems as their default. For more information, see NOW.
ExamplesDATEDIF(“2001/1/1″,”2003/1/1″,”Y”) equals 2, or two complete years in the period.
DATEDIF(“2001/6/1″,”2002/8/15″,”D”) equals 440, or 440 days between June 1, 2001, and August 15, 2002.
DATEDIF(“2001/6/1″,”2002/8/15″,”YD”) equals 75, or 75 days between June 1 and August 15, ignoring the years of the dates.
DATEDIF(“2001/6/1″,”2002/8/15″,”MD”) equals 14, or the difference between 1 and 15
-
-
WSsdckapr
AskWoody Lounger
Viewing 1 reply thread -

Plus Membership
Donations from Plus members keep this site going. You can identify the people who support AskWoody by the Plus badge on their avatars.
AskWoody Plus members not only get access to all of the contents of this site -- including Susan Bradley's frequently updated Patch Watch listing -- they also receive weekly AskWoody Plus Newsletters (formerly Windows Secrets Newsletter) and AskWoody Plus Alerts, emails when there are important breaking developments.
Get Plus!
Welcome to our unique respite from the madness.
It's easy to post questions about Windows 11, Windows 10, Win8.1, Win7, Surface, Office, or browse through our Forums. Post anonymously or register for greater privileges. Keep it civil, please: Decorous Lounge rules strictly enforced. Questions? Contact Customer Support.
Search Newsletters
Search Forums
View the Forum
Search for Topics
Recent Topics
-
Set default size for pasted photo to word
by
Cyn
2 hours, 32 minutes ago -
Dedoimedo tries 24H2…
by
Cybertooth
39 minutes ago -
Windows 11 Insider Preview build 27871 released to Canary
by
joep517
1 day, 1 hour ago -
Windows 11 ad from Campaign Manager in Windows 10
by
Jim McKenna
22 hours, 50 minutes ago -
Small desktops
by
Susan Bradley
41 minutes ago -
Totally disable Bitlocker
by
CWBillow
23 hours, 51 minutes ago -
Phishers extract Millions from HMRC accounts..
by
Microfix
23 hours, 6 minutes ago -
Windows 10 22H2 Update today (5 June) says up-to-date but last was 2025-04
by
Alan_uk
2 days, 5 hours ago -
Thoughts on Malwarebytes Scam Guard for Mobile?
by
opti1
12 minutes ago -
Mystical Desktop
by
CWBillow
2 days, 8 hours ago -
Meta and Yandex secretly tracked billions of Android users
by
Alex5723
1 day, 14 hours ago -
MS-DEFCON 2: Do you need that update?
by
Susan Bradley
6 hours ago -
CD/DVD drive is no longer recognized
by
WSCape Sand
2 days, 23 hours ago -
Windows 11 24H2 Default Apps stuck on Edge and Adobe Photoshop
by
MikeBravo
3 days, 2 hours ago -
North Face and Cartier customer data stolen in cyber attacks
by
Alex5723
3 days ago -
What is wrong with simple approach?
by
WSSpoke36
22 hours, 57 minutes ago -
Microsoft-Backed Builder.ai Set for Bankruptcy After Cash Seized
by
Alex5723
3 days, 12 hours ago -
Location, location, location
by
Susan Bradley
2 days, 2 hours ago -
Cannot get a task to run a restore point
by
CWBillow
3 days, 13 hours ago -
Frustrating search behavior with Outlook
by
MrJimPhelps
3 days, 4 hours ago -
June 2025 Office non-Security Updates
by
PKCano
4 days ago -
Secure Boot Update Fails after KB5058405 Installed
by
SteveIT
2 days, 3 hours ago -
Firefox Red Panda Fun Stuff
by
Lars220
4 days ago -
How start headers and page numbers on page 3?
by
Davidhs
4 days, 10 hours ago -
Attack on LexisNexis Risk Solutions exposes data on 300k +
by
Nibbled To Death By Ducks
3 days, 13 hours ago -
Windows 11 Insider Preview build 26200.5622 released to DEV
by
joep517
4 days, 19 hours ago -
Windows 11 Insider Preview build 26120.4230 (24H2) released to BETA
by
joep517
4 days, 19 hours ago -
MS Excel 2019 Now Prompts to Back Up With OneDrive
by
lmacri
4 days, 9 hours ago -
Firefox 139
by
Charlie
4 days, 1 hour ago -
Who knows what?
by
Will Fastie
3 days, 4 hours ago
Recent blog posts
Key Links
Want to Advertise in the free newsletter? How about a gift subscription in honor of a birthday? Send an email to sb@askwoody.com to ask how.
Mastodon profile for DefConPatch
Mastodon profile for AskWoody
Home • About • FAQ • Posts & Privacy • Forums • My Account
Register • Free Newsletter • Plus Membership • Gift Certificates • MS-DEFCON Alerts
Copyright ©2004-2025 by AskWoody Tech LLC. All Rights Reserved.