Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
curtev
 
Posts: n/a
Default Is there an automatic way to change numbers such as 12312001 t

the problem is that both solutions in this thread only work if there is a
two-digit month. if 3122004 is entered, text to columns feature will not
change to mdy format. QDE gives an error message if trying to copy data into
activated cell.

Is there a workaround for this? Thanks,

"Dave Peterson" wrote:

If they're all in a single column, do Data|text to columns
choose mdy as the format for that field.
plop it right back where you got it
format it the way you like.

LMW wrote:

I have imported a lot of dates from an old notepad file, but they came
accross as a numbers ex: December 31, 2001 is 12312001. each cell has a
number. I have formated the cells as dates, but will not recognize as a date
unless I insert / / in each cell. Is there an automatic way to change the
numbers to a date?????????


--

Dave Peterson


  #2   Report Post  
Gord Dibben
 
Posts: n/a
Default

Try this formula for 7 or 8 digit numbers.

Returns March 3, 2004 from 3122004

=IF(LEN(A1)=7,DATE(VALUE(RIGHT(A1,4)),VALUE(LEFT(A 1,1)),VALUE(MID(A1,2,2))),DATE(VALUE(RIGHT(A1,4)), VALUE(LEFT(A1,2)),VALUE(MID(A1,3,2))))


Watch out for word-wrap.....all one line.

Gord Dibben Excel MVP

On Wed, 29 Dec 2004 13:55:04 -0800, curtev
wrote:

the problem is that both solutions in this thread only work if there is a
two-digit month. if 3122004 is entered, text to columns feature will not
change to mdy format. QDE gives an error message if trying to copy data into
activated cell.

Is there a workaround for this? Thanks,

"Dave Peterson" wrote:

If they're all in a single column, do Data|text to columns
choose mdy as the format for that field.
plop it right back where you got it
format it the way you like.

LMW wrote:

I have imported a lot of dates from an old notepad file, but they came
accross as a numbers ex: December 31, 2001 is 12312001. each cell has a
number. I have formated the cells as dates, but will not recognize as a date
unless I insert / / in each cell. Is there an automatic way to change the
numbers to a date?????????


--

Dave Peterson



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
Seed numbers for random number generation, uniform distribution darebo Excel Discussion (Misc queries) 3 April 21st 23 09:02 PM
Automatic Change of X-axis Jan Charts and Charting in Excel 3 January 16th 05 07:01 PM
Sorting imported "numbers" Confused on the tundra Excel Discussion (Misc queries) 5 December 17th 04 07:33 PM
How do I change column labels from numbers to letters in Excel? AllisonCincy Excel Discussion (Misc queries) 2 December 9th 04 12:55 AM
Change row numbers Shredder Excel Discussion (Misc queries) 1 November 30th 04 10:53 PM


All times are GMT +1. The time now is 01:36 PM.

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

About Us

"It's about Microsoft Excel"