The link you give is all very good background on tasks and the activity 
stack (a.k.a. 'back stack), but how does that help the OP understand what 
is different in third-party task killers and why it has such a different 
effect on his program? If the third party task killer does it by killing 
the hosting Linux process (as it is rumored they do), then he cannot even 
count on onStop() or onDestroy() being called. Unless he can count on the 
user running Honeycomb or later, in which case he can count on onStop().

Or are you guessing that the "force close" is due to a null pointer? That 
is a very common cause, but not the only one. But in any case, the OP 
should look in the logs to see what exception immediately preceded the 
force close. Perhaps after reading the link you gave;)

On Wednesday, December 26, 2012 10:22:22 PM UTC-8, djhacktor wrote:
>
> Read this 
>
> http://developer.android.com/guide/components/tasks-and-back-stack.html
>
> On Thursday, 27 December 2012 11:32:06 UTC+5:30, Amit Dwivedi wrote:
>>
>> In my App I have several activities which are obviously related to each 
>> other. Whenever I am on some activity and the user kills my app by using 
>> any task killer. I want to do two things
>>
>>
>>    1. Clear the Notification which I added when the user logged in..
>>    2. finish all the activities other than the first Activity i.e. Login 
>>    Activity
>>
>> Now if user starts again my app either from the recent tasks or from 
>> launcher I want to start from the first activity i.e. Login Activity...
>>
>> Presently my code works absolutely fine if I use android *manage process* 
>> and 
>> end the activity or force close the app from *android task manager*. But 
>> if I am using some other task killer app i.e. Advanced task killer, after 
>> closing the app when I relaunch the App from recent apps the it tries to 
>> restart from the last used Activity instead of Login Activty and gives an 
>> ugly force close error and when I click close it redirects me back to Login 
>> Activity... The Notification is also not cleared when in this case.
>>
>> How do I handle third party task killers ?
>>
>> I have read several threads on SO but couldn't get the pointers, few of 
>> them are ...
>>
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to