this is the current state/situation: I have an Activity which binds a Service which creates AsyncTasks which downloads various web resources. That works well, but of course the ProgressBar shows nothing.
Previously i had an Activity which created an AsyncTask which downloaded some stuff. The AsyncTask got the View which holds the ProgressBar. So i could update the progress using onProgressUpdate and publishProgress. Obviously this doesn’t work any longer because I have no reference to the ProgressBar.
So, do you have any idea on how to update the progress?
Thanks in advance.
Have the
Servicenotify the then-runningActivityabout the progress fromonProgressUpdate(). That could be via a broadcastIntent, or via a callback object registered by theActivity(and unregistered when theActivityis destroyed, such as on a screen rotation).