> Well the thread is doing something at the moment I want him to be > killed. (he is downloading pictures which will be shown in the gui > later on) So I've looked at your example but don't understand how I > should implement that in my thread. I just want him to stop what he is > doing because after leaving the activity I dont need that data any > more.
I'm not real certain myself, in part because I don't have much experience with the new HttpCore/HttpClient bits. I had used the previous edition of HttpClient many a time, well before Android, but I hadn't had the need until now to get into the newer edition. My recommendation is to poke around the HTTP classes you're using and see how best to interrupt your download when you need the thread to unwind. When you tell your service to stop, it really interrupts the download and lets that thread wrap up before the service completely stops. > Could the problem be that I'm binding in the activity onStart() but > using the binded service happens in the started background thread? Possibly, but from your original post, I got the impression the error was due to the thread itself. I may be mis-interpreting that message, though. -- Mark Murphy (a Commons Guy) http://commonsware.com _The Busy Coder's Guide to Android Development_ Version 1.1 Published! --~--~---------~--~----~------------~-------~--~----~ 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] Announcing the new Android 0.9 SDK beta! http://android-developers.blogspot.com/2008/08/announcing-beta-release-of-android-sdk.html For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

