The following code:
Calendar now = Calendar.getInstance();
month = now.get(Calendar.MONTH) + 1;
year = now.get(Calendar.YEAR);
System.out.println(\"Month \"
As per the javadocs
If week year 'Y' is specified and the calendar doesn't support any week years,
the calendar year ('y') is used instead. The support of week years can be tested
with a call to getCalendar().isWeekDateSupported().
So the only problem is guess is your version of java < 1.7 because JRE1.7 has added 'Y' pattern for Week year and in JRE1.6 there is no pattern for this.
Or simply stay on the safer side use y instead of Y.
One more thing always try to use locale to be on safer side
SimpleDateFormat dt1 = new SimpleDateFormat("MMMM yyyy",java.util.Locale.ENGLISH);