Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default Dates converted into text

I receive Excel data from my branch offices.the data should contain
date coloumns.But some cells contain dates in "<year<month.<date"
format i.e.,21/02/2010 in dd/mm/yyyy format is displayed as
20100221.Why it is happening?How to convert them into dd/mm/yyyy
format?
I tried to record and run a macro to insert "/" between year and month
and between month and date,then clicking "Enter" button...But,it
displays same date in all the cells in which I run the macro.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22,906
Default Dates converted into text

Try DataText to ColumnsNextNextColumn Data Format DMY


Gord Dibben MS Excel MVP

On Thu, 4 Mar 2010 08:43:08 -0800 (PST), rjagathe
wrote:

I receive Excel data from my branch offices.the data should contain
date coloumns.But some cells contain dates in "<year<month.<date"
format i.e.,21/02/2010 in dd/mm/yyyy format is displayed as
20100221.Why it is happening?How to convert them into dd/mm/yyyy
format?
I tried to record and run a macro to insert "/" between year and month
and between month and date,then clicking "Enter" button...But,it
displays same date in all the cells in which I run the macro.


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,942
Default Dates converted into text

hi
try a formula.
=MID(B6,5,2)&"/"&RIGHT(B6,2)&"/"&LEFT(B6,4)
worked for me.
put the formula in a blank formula and copy down.
then copy the helper column and paste special values.

regards
FSt1

"rjagathe" wrote:

I receive Excel data from my branch offices.the data should contain
date coloumns.But some cells contain dates in "<year<month.<date"
format i.e.,21/02/2010 in dd/mm/yyyy format is displayed as
20100221.Why it is happening?How to convert them into dd/mm/yyyy
format?
I tried to record and run a macro to insert "/" between year and month
and between month and date,then clicking "Enter" button...But,it
displays same date in all the cells in which I run the macro.
.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 30
Default Dates converted into text

Posting the same Q 3 times ..?

1) Depends if the data is a String or Number Value ..?

Copy Data to All 3 Columns (Day/Month/Year) then format each
accordingly.

or it may be as easy as re-formatting the column..!
Select Column.. Right Click.. Format Cells..
Date.. then select the format you want
or
Custom Format.. and make your own preferred format up ..!

HTH
Andrew ;-)

"rjagathe" wrote in message
...
|I receive Excel data from my branch offices.the data should contain
| date coloumns.But some cells contain dates in "<year<month.<date"
| format i.e.,21/02/2010 in dd/mm/yyyy format is displayed as
| 20100221.Why it is happening?How to convert them into dd/mm/yyyy
| format?
| I tried to record and run a macro to insert "/" between year and
month
| and between month and date,then clicking "Enter" button...But,it
| displays same date in all the cells in which I run the macro.


  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default Dates converted into text

On Mar 4, 11:08*pm, FSt1 wrote:
hi
try a formula.
=MID(B6,5,2)&"/"&RIGHT(B6,2)&"/"&LEFT(B6,4)
worked for me.
put the formula in a blank formula and copy down.
then copy the helper column and paste special values.

regards
FSt1

hi

I put 19980427 in cell B1 and put your formula in A1.But A1 becomes
19980427 only.It does not return 27/04/1998.

regards
rjagathe

"rjagathe" wrote:
I receive Excel data from my branch offices.the data should contain
date coloumns.But some cells contain dates in "<year<month.<date"
format i.e.,21/02/2010 in dd/mm/yyyy format is displayed as
20100221.Why it is happening?How to convert them into dd/mm/yyyy
format?
I tried to record and run a macro to insert "/" between year and month
and between month and date,then clicking "Enter" button...But,it
displays same date in all the cells in which I run the macro.
.




  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default Dates converted into text

On Mar 4, 10:50*pm, Gord Dibben <gorddibbATshawDOTca wrote:
Try DataText to ColumnsNextNextColumn Data Format DMY

Gord Dibben *MS Excel MVP

On Thu, 4 Mar 2010 08:43:08 -0800 (PST), rjagathe
wrote:



I receive Excel data from my branch offices.the data should contain
date coloumns.But some cells contain dates in "<year<month.<date"
format i.e.,21/02/2010 in dd/mm/yyyy format is displayed as
20100221.Why it is happening?How to convert them into dd/mm/yyyy
format?
I tried to record and run a macro to insert "/" between year and month
and between month and date,then clicking "Enter" button...But,it
displays same date in all the cells in which I run the macro.


Hi
when I tried this, for whatever year I gave, it returns year as 1905
only.

with regards
rjagathe
  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22,906
Default Dates converted into text

Typo...............YMD should have been the format.


Gord

On Fri, 5 Mar 2010 23:35:33 -0800 (PST), rjagathe
wrote:

On Mar 4, 10:50*pm, Gord Dibben <gorddibbATshawDOTca wrote:
Try DataText to ColumnsNextNextColumn Data Format DMY

Gord Dibben *MS Excel MVP

On Thu, 4 Mar 2010 08:43:08 -0800 (PST), rjagathe
wrote:



I receive Excel data from my branch offices.the data should contain
date coloumns.But some cells contain dates in "<year<month.<date"
format i.e.,21/02/2010 in dd/mm/yyyy format is displayed as
20100221.Why it is happening?How to convert them into dd/mm/yyyy
format?
I tried to record and run a macro to insert "/" between year and month
and between month and date,then clicking "Enter" button...But,it
displays same date in all the cells in which I run the macro.


Hi
when I tried this, for whatever year I gave, it returns year as 1905
only.

with regards
rjagathe


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
Excel converted numbers to dates suddenly in All Sheets!!!! Bahareh Excel Discussion (Misc queries) 3 January 21st 09 06:03 PM
Numbers converted to Text Rashid Excel Discussion (Misc queries) 2 October 24th 08 09:38 AM
Text Converted to a Picture JM Excel Discussion (Misc queries) 0 January 12th 06 08:02 PM
Text is being converted to Date kbreiss Excel Worksheet Functions 4 November 16th 05 10:09 PM
How do I import fractions without data being converted to dates? rproeber Excel Discussion (Misc queries) 1 December 6th 04 12:53 AM


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

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"