Eric Bergman-Terrell's Blog

Android Programming Tip: Kill the Application
May 18, 2011

Ordinarily one should let the OS decide when an Android app gets killed. But you can call ExitApplication.exit() to explicitly kill the running application:

public class ExitApplication {
public static void exit() {
int processID = android.os.Process.myPid();

Use Vault 3 for Android to keep track of your important notes when you're on the go. Thanks!

Keywords: Android, Kill Process, Process ID, Process

Reader Comments

Comment on this Blog Post

Recent Posts

Node.js / Express Programming Tip: Detect and Fix Memory LeaksOctober 27, 2015
Spider Spins a Web of Deceit?October 26, 2015
Node.js / Express Programming Tip: LoggingOctober 18, 2015
Javascript / HTML Tip: How to Programmatically Copy Text from a Web Page to the ClipboardOctober 7, 2015
Don't Miss the Lunar Eclipse on Sunday & MondaySeptember 26, 2015
Node.js / Express Programming Tip: How to Implement CAPTCHASeptember 22, 2015
Node.js / Express Programming Tip: How to Upload ImagesSeptember 21, 2015