ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Convert string of digits into a date (https://www.excelbanter.com/excel-worksheet-functions/73609-convert-string-digits-into-date.html)

Scott Lolmaugh

Convert string of digits into a date
 
I have a date code in the format:
YYMMDDSS
....where "SS" is a sequence number.
I want to extract the day, month, and year data from the string and make a
date that can be used in subsequent date calculations.
Is there a function that would allow me to extract the characters from
position 5 & 6, or 3 & 4, or 1 & 2 that I can then concatonate into a proper
date format?
Thanks,
Scott



daddylonglegs

Convert string of digits into a date
 

Try

=DATE(LEFT(A1,2),MID(A1,3,2),MID(A1,5,2))


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
View this thread: http://www.excelforum.com/showthread...hreadid=515987



All times are GMT +1. The time now is 02:18 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com