Does anyone know how to do this for multiple dates if the date Strings are of variable lengths? I think the SimpleDateFormat class should help but how can it be done when one date String is August 31, 2001 14:00 GMT and another September 18, 2001 23:00 GMT ? The format is the same but the number of letters for each month changes!! I need to change it to format yyyy-mm-dd. Thanks in advance.
Joined: May 17, 2001
The length doesn't matter you tell it what format the String is in and the parse method takes care of the details.