struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Simon Kelly" <ke...@ipe.fzk.de>
Subject Re: [OT - a bit] Changing a date from dd.mm.yyyy hh:mm:ss to number of milliseconds since 1970
Date Wed, 26 Mar 2003 14:45:39 GMT
Spot on, thanks.


----- Original Message -----
From: "Mike Thompson" <mike.thompson@calebtech.com>
To: "Struts Users Mailing List" <struts-user@jakarta.apache.org>
Sent: Wednesday, March 26, 2003 3:32 PM
Subject: RE: [OT - a bit] Changing a date from dd.mm.yyyy hh:mm:ss to number
of milliseconds since 1970


See java.text.DateFormat.parse()
gets you a java.util.Date which you can call getTime() on.

Good Luck!
--m


-----Original Message-----
From: Simon Kelly [mailto:kelly@ipe.fzk.de]
Sent: Wednesday, March 26, 2003 8:28 AM
To: Struts Users Mailing List
Subject: [OT - a bit] Changing a date from dd.mm.yyyy hh:mm:ss to number
of milliseconds since 1970


Hi,

Does anyone know of a way of doing this convertion in Java or in struts for
that matter?  My db needs the milliseconds, rounded to seconds and I'm
asking the user for a date in the normal format.  As a *major* not, I can't
do the convertion client side as I have to keep the output to them as dumb
as possible (ie pure html only, *NO* JavaScripts or the like :-( )

Any pointers would be appreciated.

Cheers

Simon

Institut fuer
Prozessdatenverarbeitung
und Elektronik,
Forschungszentrum Karlsruhe GmbH,
Postfach 3640,
D-76021 Karlsruhe,
Germany.

Tel: (+49)/7247 82-4042
E-mail : kelly@ipe.fzk.de


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Mime
View raw message