Use the Match Pattern function to search for the characters you expect the user to use to delimit the month, day and year (/,-, ,). Upon the availability of the character, convert the characters before substring and check it for the corresponding part of date.