Jul 22 2022 02:36 PM
Hello,
I am looking to make a formula to convert a serial number, for example
AC21BDA123 |
into a date (month and year).
The above serial number would be year as the 1st and 2nd number (2021).
The letter after the year would be the month (A = Jan, B = Feb, etc.)
Is it possible to use a single formula to convert these? If it could be shown how to create such a formula it would be very helpful.
Thanks for the help.
Jul 22 2022 03:18 PM
SolutionJul 22 2022 03:21 PM
Jul 22 2022 03:23 PM
CODE returns the ASCII/ANSI code of a character.
The ASCII code of "A" is 65, that of "B" is 66 etc.
If we subtract 64 from that, we get the month number 1, 2, etc.
Jul 22 2022 03:33 PM
Jul 22 2022 03:18 PM
SolutionWith a serial number in A1:
=DATE(MID(A1,3,2)+2000,CODE(MID(A1,5,1))-64,1)