Ti Ru wrote:Basically what i am trying to figure out is how to make required user input in the format, mm / dd / yyyy with spaces before and after the dashes.
That code assumes there will be no spaces around the slashes (not dashes).
So if you want the user to enter spaces then you need to change lines 32 - 44 of your code.
The length of the line will no longer be 10 and you will have to check for spaces either side of where you currently set the values of symbol and symbol2.
Having said all that, you would actually be better off looking at the SimpleDateFormat class which will do all of this for you.