Gianni Costanzi Gianni Costanzi - 1 month ago 6
Android Question

How can a remote Service send messages to a bound Activity?

I've read the documentation about Bound Services, where it is shown that you can easily communicate through Messages from an Activity to a remote (i.e. not in the same context) Service but is there any way to send messages from the Service to the bound Activity? For example, my activity bounds to a running background service of the same application, sends a message to it and upon the reception of this message the service replies with a message to the activity.. how do I implement this? Can you point me to some documentation that explains this topic?

Answer

Found example in the reference documentation at Remote Messenger Service Sample.

Comments