Android - Unable to receive local broadcast in my activity from service

前端 未结 3 1626
既然无缘
既然无缘 2020-12-12 02:33

I have my main activity that start a service (Location service) and I want that service to broadcast the new location each time a new location is found.

Thanks to th

3条回答
  •  我在风中等你
    2020-12-12 03:31

    
    

    Your service is in a separate process from the activity. LocalBroadcastManager is only for use in one process. Either remove android:process from the , or use some IPC mechanism (e.g., system broadcasts, properly secured).

提交回复
热议问题