aspose file tools*
The moose likes GWT and the fly likes How to do something like 5 minutes before now in GWT Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » GWT
Bookmark "How to do something like 5 minutes before now in GWT" Watch "How to do something like 5 minutes before now in GWT" New topic
Author

How to do something like 5 minutes before now in GWT

peter tong
Ranch Hand

Joined: Mar 15, 2008
Posts: 240
As GWT has no Calendar Class as in java, I search and found there is a CalendarUtil in GWT, but it has only

and


but no any method for handling adding or subtracting hours, minutes, seconds, so how to do something like
5 minutes before current times, 1hour before current times...etc?

Gihan Pandigamage
Ranch Hand

Joined: Aug 23, 2009
Posts: 60


may be you can use this..
Maneesh Godbole
Saloon Keeper

Joined: Jul 26, 2007
Posts: 9990
    
    7

No!
The Timer or the schedule method cannot be used to manipulate the date/time


[How to ask questions] [Donate a pint, save a life!] [Onff-turn it on!]
Daniel Renner
Greenhorn

Joined: Mar 29, 2012
Posts: 10
Maybe its easier to get the necessary Time/Date with a RPC? So you can use any java function on the server. Or is this not possible/wanted in this case?

Greetings
avi sinha
Ranch Hand

Joined: Mar 15, 2009
Posts: 452

Hi Peter, why don't you just use the methods of Date class. I think using setTime & getTime, you can achieve the needful.

Thanks


SCJP 5.0 SCWCD 5.0
 
Consider Paul's rocket mass heater.
 
subject: How to do something like 5 minutes before now in GWT
 
Similar Threads
ralated to date
Looping accoridng to time
How can I make this query take less time?
How to import 2 classes with same name
Calendar object