Reputation: 11
Is there a method in codename one for getting the system's time? Like, what hour it is in the device. Also, I'd like to get the day of the week. Because I want to make a program that constantly runs a clock, and it compares int variables with the current hour, and string variables with the week day. Is there a way to do it? I'm pretty new in programming languages.
Upvotes: 0
Views: 626
Reputation: 52760
System.currentTimeMillis()
will return the time. Date
, TimeZone
and java.util.Calendar
are all available just like in standard Java.
Upvotes: 1