| Author |
Yesterdays Date
|
Mary Cole
Ranch Hand
Joined: Dec 02, 2000
Posts: 362
|
|
Hi All, How do i get yesterdays date and date 30 days bk... its urgent...
|
 |
Paul Sturrock
Bartender
Joined: Apr 14, 2004
Posts: 10336
|
|
First EaseUp. Have a look at java.util.GregorianCalendar. In particular, the getInstance() and add(int field, int amount) methods. You should be able to work it out from that.
|
JavaRanch FAQ HowToAskQuestionsOnJavaRanch
|
 |
Stan James
(instanceof Sidekick)
Ranch Hand
Joined: Jan 29, 2003
Posts: 8791
|
|
And, just in case it happens, don't think you're the first person who stared at the API half a day before realizing the amount could be negative.
|
A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi
|
 |
 |
|
|
subject: Yesterdays Date
|
|
|