Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 9
Default reformat cells for date

I have a csv file that contains a column with dates in it. Unfortunately the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I can
import it into another programme. Can any help?

Many thanks


  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 202
Default reformat cells for date

Select all the cells and then do a Format - Cells
Pick the custom format and choose DD/MM/YYYY

"Wackyracer" wrote:

I have a csv file that contains a column with dates in it. Unfortunately the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I can
import it into another programme. Can any help?

Many thanks


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 9
Default reformat cells for date

Unfortunately that does not work 10408 (01/04/08) comes out as 29/06/28.

"Dennis" wrote:

Select all the cells and then do a Format - Cells
Pick the custom format and choose DD/MM/YYYY

"Wackyracer" wrote:

I have a csv file that contains a column with dates in it. Unfortunately the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I can
import it into another programme. Can any help?

Many thanks


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default reformat cells for date

One option =DATE(2000+RIGHT(A1,2),MID(A1,LEN(A1)-3,2),LEFT(A1,LEN(A1)-4))

Another option, if your Windows Regional Settings specify d/m/y, is
=--TEXT(A1,"00\/00\/00")

Another thing worth checking is whether your CSV file actually has that
leading zero missing. If the leading zero is there but the CSV has been
opened with Excel, by default Excel would treat it as a number and not
display the leading zero. If so, read the CSV data into Excel using the Text
Import Wizard and specify the column as text.
--
David Biddulph

"Wackyracer" wrote in message
...
I have a csv file that contains a column with dates in it. Unfortunately
the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I can
import it into another programme. Can any help?

Many thanks




  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default reformat cells for date

Select the column with the "dates"
Data|Text to columns (in xl2003 menus)
Fixed width, but remove any lines that excel guessed.
Choose Date and dmy
and drop the data right back into its original location.

Then format that column the way you like.

Wackyracer wrote:

I have a csv file that contains a column with dates in it. Unfortunately the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I can
import it into another programme. Can any help?

Many thanks


--

Dave Peterson


  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 202
Default reformat cells for date

So the cells are actually numbers or text that represent the date ?
Assuming it is only the the days that are the problem and months 1-9 are
01-09 then you can create a new column with the formula
=RIGHT("0" & A1,6)

"Wackyracer" wrote:

Unfortunately that does not work 10408 (01/04/08) comes out as 29/06/28.

"Dennis" wrote:

Select all the cells and then do a Format - Cells
Pick the custom format and choose DD/MM/YYYY

"Wackyracer" wrote:

I have a csv file that contains a column with dates in it. Unfortunately the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I can
import it into another programme. Can any help?

Many thanks


  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default reformat cells for date

I had wondered about that method, but for me that doesn't work with 51208,
though it does work with 201208.
--
David Biddulph

"Dave Peterson" wrote in message
...
Select the column with the "dates"
Data|Text to columns (in xl2003 menus)
Fixed width, but remove any lines that excel guessed.
Choose Date and dmy
and drop the data right back into its original location.

Then format that column the way you like.

Wackyracer wrote:

I have a csv file that contains a column with dates in it. Unfortunately
the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I can
import it into another programme. Can any help?

Many thanks


--

Dave Peterson



  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default reformat cells for date

It worked for me in xl2003--as long as the year was only two digits.

If I used 4 digit years, then it didn't work right.

This:
51208
61208
71208
81208
91208
101208
111208
121208

converted to:
05/12/2008
06/12/2008
07/12/2008
08/12/2008
09/12/2008
10/12/2008
11/12/2008
12/12/2008

And this:

50308
60308
70308
80308
90308
100308
110308
120308

Converted to:

05/03/2008
06/03/2008
07/03/2008
08/03/2008
09/03/2008
10/03/2008
11/03/2008
12/03/2008



David Biddulph wrote:

I had wondered about that method, but for me that doesn't work with 51208,
though it does work with 201208.
--
David Biddulph

"Dave Peterson" wrote in message
...
Select the column with the "dates"
Data|Text to columns (in xl2003 menus)
Fixed width, but remove any lines that excel guessed.
Choose Date and dmy
and drop the data right back into its original location.

Then format that column the way you like.

Wackyracer wrote:

I have a csv file that contains a column with dates in it. Unfortunately
the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I can
import it into another programme. Can any help?

Many thanks


--

Dave Peterson


--

Dave Peterson
  #9   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default reformat cells for date

Perhaps it's dependent on Windows Regional Options?
--
David Biddulph

"Dave Peterson" wrote in message
...
It worked for me in xl2003--as long as the year was only two digits.

If I used 4 digit years, then it didn't work right.

This:
51208
61208
71208
81208
91208
101208
111208
121208

converted to:
05/12/2008
06/12/2008
07/12/2008
08/12/2008
09/12/2008
10/12/2008
11/12/2008
12/12/2008

And this:

50308
60308
70308
80308
90308
100308
110308
120308

Converted to:

05/03/2008
06/03/2008
07/03/2008
08/03/2008
09/03/2008
10/03/2008
11/03/2008
12/03/2008



David Biddulph wrote:

I had wondered about that method, but for me that doesn't work with
51208,
though it does work with 201208.
--
David Biddulph

"Dave Peterson" wrote in message
...
Select the column with the "dates"
Data|Text to columns (in xl2003 menus)
Fixed width, but remove any lines that excel guessed.
Choose Date and dmy
and drop the data right back into its original location.

Then format that column the way you like.

Wackyracer wrote:

I have a csv file that contains a column with dates in it.
Unfortunately
the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I
can
import it into another programme. Can any help?

Many thanks

--

Dave Peterson


--

Dave Peterson



  #10   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default reformat cells for date

I don't know. My short date format is: mm/dd/yyyy (4 digit year)

I've had trouble with this techique before, but I closed excel and reopened it
and it continued to work.

When I've had trouble, I'll use the helper column and a formula like:
=text(a1,"000000")
convert to values
and use data|text to columns.

David Biddulph wrote:

Perhaps it's dependent on Windows Regional Options?
--
David Biddulph

"Dave Peterson" wrote in message
...
It worked for me in xl2003--as long as the year was only two digits.

If I used 4 digit years, then it didn't work right.

This:
51208
61208
71208
81208
91208
101208
111208
121208

converted to:
05/12/2008
06/12/2008
07/12/2008
08/12/2008
09/12/2008
10/12/2008
11/12/2008
12/12/2008

And this:

50308
60308
70308
80308
90308
100308
110308
120308

Converted to:

05/03/2008
06/03/2008
07/03/2008
08/03/2008
09/03/2008
10/03/2008
11/03/2008
12/03/2008



David Biddulph wrote:

I had wondered about that method, but for me that doesn't work with
51208,
though it does work with 201208.
--
David Biddulph

"Dave Peterson" wrote in message
...
Select the column with the "dates"
Data|Text to columns (in xl2003 menus)
Fixed width, but remove any lines that excel guessed.
Choose Date and dmy
and drop the data right back into its original location.

Then format that column the way you like.

Wackyracer wrote:

I have a csv file that contains a column with dates in it.
Unfortunately
the
column has the information entered as DMMYY for 5/12/08 or DDMMYY for
20/12/08. So for days 1st to 9th there is no 0 at the front end.

I need to be able to change this coloumn so it reads DD/MM/YYYY so I
can
import it into another programme. Can any help?

Many thanks

--

Dave Peterson


--

Dave Peterson


--

Dave Peterson


  #11   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default reformat cells for date

David

51208 becomes May 12, 2008 when I run it through T to C and select MDY as format

What are your short date settings?


Gord Dibben MS Excel MVP

On Wed, 2 Apr 2008 20:51:21 +0100, "David Biddulph" <groups [at]
biddulph.org.uk wrote:

I had wondered about that method, but for me that doesn't work with 51208,
though it does work with 201208.
--
David Biddulph


  #12   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,651
Default reformat cells for date

02/04/2008
in other words
DD/MM/YYYY
--
David Biddulph

"Gord Dibben" <gorddibbATshawDOTca wrote in message
...
David

51208 becomes May 12, 2008 when I run it through T to C and select MDY as
format

What are your short date settings?


Gord Dibben MS Excel MVP

On Wed, 2 Apr 2008 20:51:21 +0100, "David Biddulph" <groups [at]
biddulph.org.uk wrote:

I had wondered about that method, but for me that doesn't work with 51208,
though it does work with 201208.
--
David Biddulph




  #13   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default reformat cells for date

Mine are mm/dd/yyyy so that's the difference.


Gord

On Wed, 2 Apr 2008 22:58:04 +0100, "David Biddulph" <groups [at]
biddulph.org.uk wrote:

02/04/2008
in other words
DD/MM/YYYY


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to reformat numbers C.Loner Excel Discussion (Misc queries) 4 January 23rd 08 12:31 AM
Reformat numbers EllenM Excel Discussion (Misc queries) 6 August 8th 07 04:22 PM
Reformat spreadsheet JoP Excel Worksheet Functions 1 July 5th 07 06:09 PM
Reformat Table [email protected] Excel Discussion (Misc queries) 4 December 23rd 06 09:50 AM
How to Stop Reformat When Cells Are Copied Strong Eagle Excel Discussion (Misc queries) 1 April 30th 06 02:42 AM


All times are GMT +1. The time now is 07:32 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"