View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Jacob Skaria Jacob Skaria is offline
external usenet poster
 
Posts: 8,520
Default Converting Identification Number to Birthday

Apply this formula in B1 and drag to other rows. Format Column B Cells to
Date dd-mmm format

=IF(LEFT(A3,1)<"P",DATE(MID(A3,1,2),MID(A3,3,2),M ID(A3,5,2)),"")


If this post helps click Yes
---------------
Jacob Skaria


"WildWill" wrote:

I have a cell (A1) that could contain one of two types of data:

1) Passport Number which is in the format of "PXXXXX" where X = numeric
digits.
2) a standard ID number which has the format "YYMMDD XXXX XX X" where the
first 6 digits represent the persons birth date. I need a formula that will
look into the data entered into A1, and:

If the entered data is in the format of the Passport Number, do nothing.
If the entered data is in the format of the id number, extract the day and
month of the persons birthdate and place that data in B1, with the format '15
Feb" - not showing the year value.