• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps Can we change the device time using an application?

Hi everyone..

Trying to find out whether it is possible to change the TIME of the DEVICE using a third party application for us developers. Does the Android OS allow that kind of dev access to the device clock?

If so, could you direct me to any API / Class which allows us to do so?
(trying to find a definitive answer for a client.. :) )

Thanks in advance!
 
While I don't know for sure, I would guess that you could only do that if you had a rooted phone. Normally that's only something that you can do with that permission.
 
I looked a little more into it, and you might be able to set the system time. Try using setCurrentTimeMillis() in android.os.SystemClock It says that you need to have the appropriate permissions , but it may work.
 
Back
Top Bottom