=TEXT(IF(LEN(A1)=15,"19","")&MID(A1,7,6+2*(LEN(A11)=18)),"00000000")
=date(mid(a1,7,2+2*(len(a1)=18)),mid(a1,9+2*(len(a1)=18),2),mid(a1,11+2*(len(a1)=18),2))