Calendar a = new Calendar();
a.set(Calendar.DAY_OF_WEEK, Calendar.SUNDAY);
Date b = Calendar.getTime();
As an example. There's a bit more to it, depending on exactly what you want to do, but that's a start (and more than a start).
masijade
Industrious Poster
4,253 posts since Feb 2006
Reputation Points: 1,471
Solved Threads: 494
Look at the add method of Calendar (hint, you can give it negative numbers). Cycle backwards and use get(Calendar.DAY_OF_WEEK) and compare it to the GregorianCalendar method getFirstDayOfWeek().
masijade
Industrious Poster
4,253 posts since Feb 2006
Reputation Points: 1,471
Solved Threads: 494
No. If you go backwards a day, you go backwards a day. It's a Calendar. Just like the one you have on the wall.
masijade
Industrious Poster
4,253 posts since Feb 2006
Reputation Points: 1,471
Solved Threads: 494