Hi,
Have for two question in date function
1. How to convert MM-DD-YYYY to DD-MM-YYYY & wise-versa in date function?
2. How to convert a Text Format to Date Format?
Please Help. Thanks in advance
Hi,
Have for two question in date function
1. How to convert MM-DD-YYYY to DD-MM-YYYY & wise-versa in date function?
2. How to convert a Text Format to Date Format?
Please Help. Thanks in advance
You choose or create a Custom Number format. From the Format menu choose Cells>-Number>-Custom.
How are your dates input as Text?
Hope that helps.
RoyUK
--------
For Excel Tips & Solutions, free examples and tutorials why not check out my web site
Free DataBaseForm example
One way that I found is to right click the cell, go to format cells, then click date from the list given. The date option then allows you to choose various styles of date formatting.
If you don't like any of the styles there, click custom, then you can type it mm-dd-yy or yy-dd-mm or dd-mm-yy. I hope that helps.
If your dates appear as a date form recognizable to Excel, but are still being treated as text, put a 0 in a cell, copy that cell, then highlight all the dates, Paste Special -> Add. This should convert them all to actual dates.
Another method of converting dates that are treated as text
Select Dates
Data Menu
Text To Column
Delimited - Untick all options (Can also use Fixed Width)
Next
Select Date Option
Finish
Please Read Forum Rules Before Posting
Wrap VBA code by selecting the code and clicking the # icon or Read This
How To Cross Post politely
Top Excel links for beginners to Experts
If you are pleased with a member's answer then use the Scales icon to rate it
If my reply has assistedor failed to assist you
I welcome your Feedback.
Years late, but thank you! And the fact that you from from Melbs make it even better ;-) Thanks for saving me countless hours of work with something so simple!
I know you have already found a solution, but somebody else may find this while searching for a solution. You can convert a text date to a date value with the DATEVALUE function. This wont change MM/DD/YYYY to DD/MM/YYYY though and if your default is DD/MM/YYYY it will show, for example May 3 2013 (displayed as text as 05/03/2013), as 5 March 2013. There is another more complicated formula you could use though. If the text date is in cell A1 you could use this formula: =DATE(VALUE(RIGHT(A1,4)),VALUE(LEFT(A1,FIND("/",A1)-1)),VALUE(MID(A1,FIND("/",A1)+1,2))). This of course assumes the text date is in the D/MM/YYYY format. It can be altered to match other formats, eg replacing "/" with "-" if necessary.
Last edited by gak67; 04-23-2014 at 12:03 AM. Reason: I made an error
Thanks for the update, gak, and welcome to the forum![]()
1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
2. If your question is resolved, mark it SOLVED using the thread tools
3. Click on the star if you think someone helped you
Regards
Ford
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks