How to add 7 days to current date while not going over available days of a month?

前端 未结 8 1003
长发绾君心
长发绾君心 2020-12-06 17:16

I am trying to get todays day of the month.

And what i want to do is add seven days to the number and the get that current day of the month.

Also i want it t

相关标签:
8条回答
  • 2020-12-06 17:53

    cal.add(Calendar.DAY_OF_MONTH, 7);

    0 讨论(0)
  • 2020-12-06 17:55

    You have to use the add method of calendar.

    cal.add(Calendar.DAY_OF_MONTH, 7);
    
    0 讨论(0)
提交回复
热议问题