ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Change Date (https://www.excelbanter.com/excel-discussion-misc-queries/23283-change-date.html)

Quandary

Change Date
 
I have a rather large list of dates that are in a column and are written
first as year then month then day Ex: 20051116. I want to change all of them
in a date format like this 11/16/2005 with out retyping each one. I have
tried to change the format but excel will not read it. I have tried to make a
macro but excel only changed that one cell not the entire column. Please
help.

RagDyer

It's relatively easy, *IF* all your dates are entered the same.

That means 4 digits for the year and 2 each for the month an day.
You can understand the ambiguity of something like this:
2005121

Which could be:
20050121
20051201

TTC (Text To Columns), can decipher your numbers and convert them to *true*
XL dates, where you then simply format them to the display mode that you
wish.

Select the list (in a column), then:
<Data <Text To Columns, <Next <Next
Click in "Date", and expand the date window and choose the format that you
now *have* (YMD), and wish to convert, *not* the format that you want to end
up with.

Now, click <Finish

You should now have your proper dates, which you can now format any way you
wish, if you don't like the format XL chose.
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================


"Quandary" wrote in message
...
I have a rather large list of dates that are in a column and are written
first as year then month then day Ex: 20051116. I want to change all of them
in a date format like this 11/16/2005 with out retyping each one. I have
tried to change the format but excel will not read it. I have tried to make
a
macro but excel only changed that one cell not the entire column. Please
help.


Dave Peterson

Select that range in the column
data|Text to columns
fixed width (but remove any lines that excel guessed)
make sure you choose YMD as the date type



Quandary wrote:

I have a rather large list of dates that are in a column and are written
first as year then month then day Ex: 20051116. I want to change all of them
in a date format like this 11/16/2005 with out retyping each one. I have
tried to change the format but excel will not read it. I have tried to make a
macro but excel only changed that one cell not the entire column. Please
help.


--

Dave Peterson


All times are GMT +1. The time now is 09:05 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com