how to retireve date from day in java

hi i have function which takes day as input i would like to get the date corrosponding to that day
[105 byte] By [har_para] at [2007-11-26 21:23:47]
# 1
Do you mean you got the "DATE", and you want the "DAY" ?Date containssecond, minute,hour, Day, Month, Yearread this one http://java.sun.com/j2se/1.4.2/docs/api/java/util/Date.html
rym82a at 2007-7-10 3:03:28 > top of Java-index,Java Essentials,Java Programming...
# 2
can you please explain clearly?what you mean by take a day as input? Monday to sunday as input? number of day in a year?
ccwoon80a at 2007-7-10 3:03:28 > top of Java-index,Java Essentials,Java Programming...
# 3
If I can guess correctly what you mean :-) create an instance of GregorianCalendar, set its DAY_OF_WEEK to the day you have (say, Friday) and voil? you have the date (say, March 16, 2007).
OleVVa at 2007-7-10 3:03:28 > top of Java-index,Java Essentials,Java Programming...
# 4
At least post the method's signature ;-)
benubacha at 2007-7-10 3:03:28 > top of Java-index,Java Essentials,Java Programming...
# 5

> At least post the method's signature ;-)

public void Calendar.set(int field, int value)

Calendar is the superclass of GregorianCalendar.

If your smiley indicated a joke, I didn't get it, so I take as just a sign of friendliness.

Message was edited by:

OleVV

OleVVa at 2007-7-10 3:03:28 > top of Java-index,Java Essentials,Java Programming...
# 6
> > At least post the method's signature ;-)> If your smiley indicated a joke, I didn't get it, so> I take as just a sign of friendliness.I'm sorry, the request was meant to the OP I should have specified that ;-)
benubacha at 2007-7-10 3:03:29 > top of Java-index,Java Essentials,Java Programming...
# 7
> I'm sorry, the request was meant to the OP I should> have specified that ;-)No worries. No harm done.I agree that the original question wasn't clear.
OleVVa at 2007-7-10 3:03:29 > top of Java-index,Java Essentials,Java Programming...