|
In V4R5 the Java date is **always** assumed to be in GMT, unless you specifically set the time zone. The way I do this is to set the appropriate system property when calling the Java class, like this: java -Duser.timezone=Europe/London yourClass or by using PROP(user.timezone 'Europe/London') in the RUNJVA command. An earlier response to one of your messages referred to a tip on the Ignite/400 site that suggested setting this property in a file whose location I forget. PC2 -----Original Message----- From: Keith_McCully@wunderman.co.uk [mailto:Keith_McCully@wunderman.co.uk] Sent: August 6, 2002 08:42 To: java400-l@midrange.com Subject: RE: JavaMail API: SentDate problem Gary, You're right, the message was sent at 9:11:14 BST. It seems that the actual time is correct but the time zone wrong. I'm not sure but I think the JVM time is set from the system variable QTIME which does not get automatically updated for daylight saving. As far as I know, the time zone is not updated or is that intentional as strictly BST is not a time zone but a daylight saving feature of GMT? System.err.println(msg.getSentDate().toString()) gives Tue Aug 06 16:27:32 GMT 2002 and again the time is right but should be BST or GMT+01:00. Also, TimeZone tz = TimeZone.getTimeZone("Europe/London") and TimeZone.getDefault() give time zone GMT+00:00. Regards, Keith
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.