Sponsored Link •
|
Advertisement
|
Advertisement
|
This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.
Message:
Why are you doing that silly parseInt() stuff? All the tools you need are built into DateFormat() and Date(). If you have a string in a date, use DateFormat.parse() to get a Date object, which has the necessary methods for getting year, month and day. - mfg > thanx fer the advise. the jscript works fine!! > for JAVA however, my fren proposed that i use the SimpleDateFormat. it's kinda sloppy. ehe. but it gets the job done. > SimpleDateFormat dateFmt = > year = Integer.parseInt(dateString.substring(2,4))+100;
Replies:
|
Sponsored Links
|