Convert date to different format

DMP3

New Member
Joined
Aug 11, 2010
Messages
11
I have a formula which returns the date in yymmdd for which I want to convert to a serial date.

example:
in cell J6 I have this formula = RIGHT(LEFT(B6,12),6)
which returns "110319"

I want to convert this date (110319 which is yymmdd) to a serial date (ie 40621)

I appreciate any help!
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
Replace your formula in J6 with this
Code:
=DATE(Concatenate("20",LEFT(RIGHT(LEFT(B6,12),6),2)),MID(RIGHT(LEFT(B6,12),6),3,2),RIGHT(RIGHT(LEFT(B6,12),6),2))
This formula does require that all date values are always 2 digits.

Caution- this formula will only work with dates through the year 2099
 
Last edited:
Upvote 0
Replace your formula in J6 with this:

=TEXT(MID(B6,9,4)&MID(B6,7,2),"00\/00\/00")+0
 
Upvote 0

Forum statistics

Threads
1,224,586
Messages
6,179,719
Members
452,939
Latest member
WCrawford

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