tag:blogger.com,1999:blog-4110922097903883980.post1431705614485056533..comments2022-04-11T01:02:36.890-07:00Comments on Lotus and Java: DateTime.toJavaDate() issueAndriy Kubahttp://www.blogger.com/profile/04831973985838292453noreply@blogger.comBlogger4125tag:blogger.com,1999:blog-4110922097903883980.post-90601644296854387922014-09-24T09:50:31.466-07:002014-09-24T09:50:31.466-07:00This was a helpful but in my case the time being s...This was a helpful but in my case the time being set was the current time LESS GMT adjustment (in my case 5 hours GMT-5 EST). This creates a problem if the current time is shortly after midnight. The toJavaTime() is being adjusted minus 5 hours to the PRIOR DAY. <br /><br />I found this solution accounts for all scenarios:<br /><br /> notesDateTime.setLocalTime(notesDateTime.getDateOnly() + " 00:00:00");<br /> Date javaResult = notesDateTime.toJavaDate();Andy Connhttps://www.blogger.com/profile/11219731056286905971noreply@blogger.comtag:blogger.com,1999:blog-4110922097903883980.post-25457239081460855582013-12-18T06:59:05.577-08:002013-12-18T06:59:05.577-08:00Actually, a small change - I think you want:
jCal...Actually, a small change - I think you want:<br /><br />jCalendar.set(Calendar.HOUR_OF_DAY, 0);Stuart Orfordhttps://www.blogger.com/profile/16906626735900600292noreply@blogger.comtag:blogger.com,1999:blog-4110922097903883980.post-64556369047705072782013-12-18T06:37:04.382-08:002013-12-18T06:37:04.382-08:00Agh! Thanks for this, I spent hours this morning w...Agh! Thanks for this, I spent hours this morning working out why I couldn't get two dates to be equal.Stuart Orfordhttps://www.blogger.com/profile/16906626735900600292noreply@blogger.comtag:blogger.com,1999:blog-4110922097903883980.post-22701677114789390902013-12-18T06:35:23.574-08:002013-12-18T06:35:23.574-08:00This comment has been removed by the author.Pete Cliffordhttps://www.blogger.com/profile/05154523988927844082noreply@blogger.com