If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

comparing dates

hey i want to know how to compare dates that a user has typed in, a user types the date in the text fields provided and I want to be able to compare them. I dont want any output from the method, which i have currently i want it to just compare dates like "compareTo" does for String. Thanks.

you make 2 instances of the Calendar object, set their fields with the set() method, then convert them to longs, subtract, then convert the long back to a calendar object, with all the fancy division implied.

of course, i could be completely off base, and you probably could just do it with the wonderful Date object and compile it with a deprecated sdk, or there could be a method i missed, or you could probably google one up, but there ya go.