Thanks again a lot for your replies. On 24 Giu, 01:31, Mark Murphy <[email protected]> wrote: > On Wed, Jun 23, 2010 at 7:24 PM, Federico Paolinelli <[email protected]> > wrote: > > If I understood correctly, I need to bind to the service in order to > > provide it a listener, and then if I want to use the onProgressUpdate > > for an AsyncTask started from the service, I should notify the > > listener from the onProgressUpdate call. Is it correct? > > That is certainly one approach. >
I wasn't aware of the possibility to pass a listener to the service after the bind, I thought that the bind was useful just from activity --> service. > > I thought that the standard way to update the ui from a service was to > > send an Intent (but in this way I wouldn't be aware of the state of > > the activity). > > That is another approach. I am not sure that I would necessarily cal > it the "standard way", but you are certainly welcome to do that. In > that case, the service would broadcast the Intent, and if an activity > picks it up, great. By "the standard way" I meant the way described in all the examples I read (maybe I gotta read some other examples) > > -- Thanks again for the exhaustive and quick replies. Federico -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

