Forcefully closing my application

Put your problem here if it does not fit any of the other categories.

Forcefully closing my application

Postby parimalraj2000 » Wed Nov 12, 2008 5:48 am

Hello,

I want to forcefully close my application. I have tried with finish() but it's going to the last activity without closing the application. Can anybody please let me know how I can do that?

Thanks for your help in advance.

Regards,
Parimal.
parimalraj2000
Junior Developer
Junior Developer
 
Posts: 18
Joined: Tue Nov 04, 2008 10:01 am

Top

Postby MrSnowflake » Wed Nov 12, 2008 8:51 am

You can't! Only Android itself can close a whole task (=application). You could start all child Activitys ForResult, so when a certain resultCode is returned, you finishActivity(CLOSE_ALL) every parent, so eventually you reach the 1st activity on the Stack and if that's finished, you're done.
User avatar
MrSnowflake
Moderator
Moderator
 
Posts: 1439
Joined: Sat Feb 16, 2008 3:11 pm
Location: Flanders, Belgium

Top

Return to Other Coding-Problems

Who is online

Users browsing this forum: No registered users and 19 guests