Skip to content Skip to sidebar Skip to footer

How To Destroy My Application?

My application is always showing in Task Manager when I exit from my application. How do I destroy it? I used the onDestroy() method, but still it is running. I am using alarm man

Solution 1:

Android does not destroy applications unless it needs to. See this answer for more details: Is quitting an application frowned upon?

Solution 2:

System.exit(0) will do the job. However, it is not at all recommended. Android does some caching, and saving state, so as to relaunch your appp quicker, the next time you launch it.. so you do not want to be messing around with that.

Solution 3:

Its not a problem. thats how android works, terminating Application is done by os. But if you want to kill it then you may have to kill the process.

Post a Comment for "How To Destroy My Application?"