Solved

Excell date formatting question

Posted on 2012-04-05
8
331 Views
Last Modified: 2012-04-09
Hi guys,

I currently have a row in excel with the data in the following format 9903 (yymm) I need to format this into a date and I can't get it work, I don't see any options in excel with the (yymm) formatting.
My final goal is to convert that date to years to get the age of an account.

Any help will be great!
Thanks.
0
Comment
Question by:exTechnology
8 Comments
 
LVL 45

Assisted Solution

by:Martin Liss
Martin Liss earned 100 total points
ID: 37813122
Format->Number->Custom

and then yymm
0
 
LVL 13

Expert Comment

by:Shanan212
ID: 37813196
whats your expected results?
0
 
LVL 43

Accepted Solution

by:
Saqib Husain, Syed earned 200 total points
ID: 37813197
if your data is in A1 then you can try

=date(left(a1,2),right(a1,2),1)
0
 
LVL 2

Author Comment

by:exTechnology
ID: 37813231
my expected result is to format the date that is currently raw 9902 (yymm) to an age, the amount of years from today's date.
0
6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

 
LVL 43

Assisted Solution

by:Saqib Husain, Syed
Saqib Husain, Syed earned 200 total points
ID: 37813252
Then try

=year(today())-left(A1,2)
0
 
LVL 13

Assisted Solution

by:Shanan212
Shanan212 earned 100 total points
ID: 37813759
partially using ssaqibh's formula:

=ROUND((TODAY()-DATE(LEFT(A1,2),RIGHT(A1,2),1))/365,0)

Open in new window


Using today, this would yeild 13 (years)
0
 
LVL 80

Assisted Solution

by:byundt
byundt earned 100 total points
ID: 37814593
If you require full years difference, then you might try:
=DATEDIF(--(RIGHT(A1,2) & "/" & LEFT(A1,2)),TODAY(),"y")
0
 
LVL 78

Expert Comment

by:David Johnson, CD, MVP
ID: 37816511
remember that saquib's solution do NOT change the formatting of the column A (do not use custom formatting yymm)
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…
Learn how to make your own table of contents in Microsoft Word using paragraph styles and the automatic table of contents tool. We'll be using the paragraph styles in Word’s Home toolbar to help you create a table of contents. Type out your initial …

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now