@Anonymust,
Try this
=MAX(IFERROR(MID(A1,1,ROW(INDIRECT("1:"&LEN(A1))))*1,""))
Confirmed with Ctrl-Shift-Enter