Convert Date/Time Format

Bullflip

New Member
Joined
Jun 2, 2020
Messages
19
Office Version
  1. 365
Platform
  1. Windows
How do I convert the following:

2/24/2022 10:02:11 AM

To this:
2/24/2022 10:12:11

How do I just drop the AM part? For some reason, Tableau won't read the first one, but it reads the second one.
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
is it a format issue ? or is it entered as text

format the cell to general and see if you just get a number

then use format
mm/dd/yyyy h:mm:ss
 
Upvote 0
is it a format issue ? or is it entered as text

format the cell to general and see if you just get a number

then use format
mm/dd/yyyy h:mm:ss
Hi, I tried formatting it to general and it stays the same. So I think it's entered in as text.
 
Upvote 0
if its text , you will need VBA to change the cell contents themselves
a formula will have to be in a different cell

do you want in a different cell if not - VBA not my area

will months / days with single digits have a leading zero
02/03/2022
OR
2/3/2022
 
Upvote 0
Hi,

You should be able to do just this, then, copy/paste/value into the original cell if you want:

Book3.xlsx
AG
122/24/2022 10:02:11 AM
132/24/2022 10:02:11<format as m/d/yyyy h:mm:ss
14or however you want
Sheet1032
Cell Formulas
RangeFormula
A13A13=A12+0
 
Upvote 0
Also try:

Select your Text date cell
Click on "Data" Tab, Click "Text to Columns"
Click "Finish"

It should change your Text date to Real Date, then format to display as you like.
 
Upvote 0
Also try:

Select your Text date cell
Click on "Data" Tab, Click "Text to Columns"
Click "Finish"

It should change your Text date to Real Date, then format to display as you like.
Thank you!
 
Upvote 0

Forum statistics

Threads
1,215,064
Messages
6,122,936
Members
449,094
Latest member
teemeren

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