This week's book giveaway is in the Mac OS forum. We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line! See this thread for details.
You used SimpleDateFormat to parse a date string into a Date object (which you then used to set the calendar with). To convert a date back to a string, you use the SimpleDateFormat object again, but you call format(...) instead of parse(...). For example:
Note that the method getTime() of class Calendar gives you a Date object, which you can pass to the format(...) method of class SimpleDateFormat to convert it to a String.
Is there a reason why you don't want to do it with a SimpleDateFormat object as I proposed ?
Months in the Java Calendar class are 0-based: 0 = January, 1 = February, ..., 7 = August, ..., 11 = December. So if you do cal.get(Calendar.MONTH), you'll get a number from 0 to 11, not 1 to 12. You need to add 1 yourself if you want to interpret this as a regular month number yourself.