Does broadcast receiver work in background?

KellyPoima

New member
Does broadcast receiver work in background?
Answer
You receiver stops working, because you construct it in onCreate, which means it will live as long as your app is alive. … If you want a background receiver, you need to register it inside the AndroidManifest (with intent filter), add an IntentService and start it when you receive a broadcast in the receiver.
 

Tìm kiếm

Back
Top