0

I want to start binder service once application receive broadcast, So can i bind service from receiver like startService or do i need to send callback to activity to bind service? As per my knowledge broadcast receiver has time limit of 10 sec, so does that time limit would affect if i bind service from receiver?

Reena
  • 1,368
  • 1
  • 11
  • 25

1 Answers1

1

BroadcastReceiver cannot bind to a service. More specifically, the context provided in onReceive() cannot be used to bind to a service or to register dynamic BroadcastReceivers. You will need to start an Activity or Service of your own.

Karakuri
  • 38,365
  • 12
  • 84
  • 104