N
N
Nurshat2016-05-11 14:41:33
Java
Nurshat, 2016-05-11 14:41:33

How to make the timer not stop when the device is locked?

There is a timer (android class) that performs certain actions every minute, but such a problem was found that when the device is locked, the timer stops working and resumes its work only after unlocking, how can I solve this problem?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
Eugene, 2016-05-11
@Ragnar0k

Because when blocking, the activity is destroyed, and all the processes that were running in it.
Use the Service class to keep processes running in the background.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question