Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / New Users / December 2007

Tip: Looking for answers? Try searching our database.

Getting date stored as text into real date?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ed from AZ - 17 Dec 2007 13:12 GMT
A database query program outputs everything as a text string.  One of
the fields is a date, formatted as yyyymmdd.  Is there a worksheet
function that will change this to an Excel-recognized date?  Or a
macro?  The error checking doesn't flag this.

Ed
Pete_UK - 17 Dec 2007 14:36 GMT
With your text date in A1, try this in B1:

=DATE(LEFT(A1,4),MID(A1,5,2),(RIGHT(A1,2))

Hope this helps.

Pete

> A database query program outputs everything as a text string.  One of
> the fields is a date, formatted as yyyymmdd.  Is there a worksheet
> function that will change this to an Excel-recognized date?  Or a
> macro?  The error checking doesn't flag this.
>
> Ed
JE McGimpsey - 17 Dec 2007 14:45 GMT
Don't need a macro - Select your dates and choose Data/Text to Columns.
Click Next, Next, then choose yymmdd from the Date dropdown. Click
Finish. Format the dates as desired.

In article
<250cc4a4-a397-4f3b-b19b-00337981a990@e6g2000prf.googlegroups.com>,

> A database query program outputs everything as a text string.  One of
> the fields is a date, formatted as yyyymmdd.  Is there a worksheet
> function that will change this to an Excel-recognized date?  Or a
> macro?  The error checking doesn't flag this.
>
> Ed
Ed from AZ - 17 Dec 2007 17:35 GMT
That worked great!!

Thanks!!
Ed

> Don't need a macro - Select your dates and choose Data/Text to Columns.
> Click Next, Next, then choose yymmdd from the Date dropdown. Click
[quoted text clipped - 11 lines]
>
> - Show quoted text -

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.