Article View: borland.public.jbuilder.java.language
Article #19144Re: Date type to/from string
From: James D. Frentress
Date: Tue, 10 Mar 1998 00:00
Date: Tue, 10 Mar 1998 00:00
19 lines
1007 bytes
1007 bytes
Tad Frysinger wrote:
> Any other ideas?
>
use the Calendar and/or GregorianCalendar classes.
you can do this sort of thing:
Date myDate = new Date();
SimpleDateFormat df = new SimpleDateFormat("EEE MMM dd HH:mm:ss
yyyy");
String myStringDate = df.format(myDate);
with the classes mentioned above, you can reconstruct myStringDate into
a date.
Jim
Technical Details
Message-ID:
<3505D755.B6F361B@ForAWhile.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<MPG.f6f3422293a76d09897c7@forums.borland.com> <35059639.B429F072@csi.com> <MPG.f6f7f045dce2f2d9897cb@forums.borland.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f74b3,97ec465ac7d926cb X-Google-Attributes: gidf74b3,public From: "James D. Frentress" <Broken@ForAWhile.com> Subject: Re: Date type to/from string Date: 1998/03/10 Message-ID: <3505D755.B6F361B@ForAWhile.com> X-Deja-AN: 332792969 Content-Transfer-Encoding: 7bit References: <MPG.f6f3422293a76d09897c7@forums.borland.com> <35059639.B429F072@csi.com> <MPG.f6f7f045dce2f2d9897cb@forums.borland.com> X-Priority: 3 (Normal) Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Organization: Microsoft Newsgroups: borland.public.jbuilder.java.language