Different date formats

alexmols

New Member
Joined
Dec 7, 2010
Messages
13
Hello all,

i have received an automatically generated file which contains a long list of dates which have two different date formats, unfortunately. Examples of these two formats are:

1-12-2010
1/13/2010 12:23:29 AM

Note:
the first format is d/mm/yyyy
the second format is m/dd/yyyy (hh:mm:ss AM)

Is there a way by which I can get the column next to it, to contain one single date format, preferably dd/mm/yyyy

Thanks in advance,
Alex Mols
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
I assume you have copied the date you wish to format into the new column and then: format, date format and choose what you want?
 
Upvote 0
Thank you for your quick reactions!

The first example (1-12-2010) is indeed recognised as a date, but the second one (with AM) isn't. It gives as format "standard".

I have indeed copied the date into a new cell and chose my preferred date format as format, but this only works for the (1-12-2010) and not for the other one. Even when creating a custom format and labelling:
1/13/2010 12:23:29 AM
as
m/dd/yyyy hh:mm:ss AM/PM
does not enable me to create a simpler format (or at least I do not know how)
 
Upvote 0
Try this formula, update A1 to the appropriate cell
Code:
=TEXT(A1,"dd/mm/yy")


This doesn't work for the date which is given as:
1/13/2010 12:23:29 AM

Any other idea's? It's over 3000 dates so I really don't want to do it by hand...
 
Upvote 0
Here's a convoluted formula you can try...
Code:
=CONCATENATE(MID(A2,(FIND("/",A2,1)+1),2),"/",LEFT(A2,(FIND("/",A2,1)-1)),"/",MID(A2,(FIND(" ",A2,1)-4),4))
 
Upvote 0
I've got excel 2007 (and it's in Dutch instead of English) which makes I can't find the menu you suggested. Do you know where to find this menu in excel 2007?

I did find out that the problem lies with the switch in dd/mm or mm/dd. Since "we" in The Netherlands use a standard format of dd/mm/yyyy but some of the dates are shown as mm/dd/yyyy.

Because even if I remove the time and AM/PM from a cell, it still doesn't convert it correctly.
 
Upvote 0

Forum statistics

Threads
1,224,522
Messages
6,179,297
Members
452,903
Latest member
Knuddeluff

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top