java - Get all days between tomorrow and 60 days forward then loop through them -


i need take tomorrow, add 60 days , loop on day day. wondering appropriate way of doing this?

this tried. somehow starts loop month , in january 2015 shows month 0.

    calendar startcalemder = calendar.getinstance();     startcalemder.settime(new date());     startcalemder.add(calendar.date, 1);      calendar endcalendar = calendar.getinstance();     endcalendar.settime(new date());     endcalendar.add(calendar.date, 60);      //loop on day day     (; startcalemder.compareto(endcalendar) <= 0;             startcalemder.add(calendar.date, 1)) {         startcalemder.get(calendar.year); //shows year         startcalemder.get(calendar.month); //shows month         startcalemder.get(calendar.day_of_month); //shows day     } 

your code alright. need understand crazy calendar api 0 means january , 10 means november.

https://docs.oracle.com/javase/7/docs/api/constant-values.html#java.util.calendar.january


Comments

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -