Solved

convert custom to date

Posted on 2014-02-17
6
262 Views
Last Modified: 2014-02-17
I have a column in excel (formatted custom 00000000) which actually represents a date. Is there any easy way to change the format to dd/mm/yyyy? WHen I cut and paste it elsewhere and re-apply the formatting, the dates go all over the place.
0
Comment
Question by:pma111
  • 3
  • 2
6 Comments
 
LVL 19

Expert Comment

by:regmigrant
ID: 39864898
if your 'date' is in a1 and is formatted as (for example) 17022014 (ie: today)
=DATE(RIGHT(a1,4),MID(a1,3,2),LEFT(a1,2)) will give you a formatted date

post an example if that's not what the right interpretation
0
 
LVL 3

Author Comment

by:pma111
ID: 39864913
Just tried this, the original date (1st april 2013)

01042013      

returned (with the above formula):

00042531
0
 
LVL 3

Author Comment

by:pma111
ID: 39864918
formatted the column dd/mm/yyyy then reapplied the formula, but its still off.

for example

02022014

returns (with the above formula)

20/10/2015
0
Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

 
LVL 19

Accepted Solution

by:
regmigrant earned 250 total points
ID: 39864951
ok, the formula is losing the leading 0 because they are numbers, assuming you don't want to put an apostrophe in front of them all :-

=DATE(RIGHT(TEXT(B31,"00000000"),4),MID(TEXT(B31,"00000000"),3,2),LEFT(TEXT(B31,"00000000"),2))
0
 
LVL 50

Assisted Solution

by:barry houdini
barry houdini earned 250 total points
ID: 39865686
If you use TEXT function like this it will handle single or double digit days

=TEXT(A1,"00-00-0000")+0

Format as dd/mm/yyyy

regards, barry
0
 
LVL 19

Expert Comment

by:regmigrant
ID: 39865713
always believe Barry :)
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This Article is a follow-up to my Mappit! Addin Article (http://www.experts-exchange.com/A_2613.html), it was inspired by an email posting I made to EUSPRIG (http://www.eusprig.org/index.htm), I will briefly cover: 1) An overvie…
How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.

786 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