Calling a new Activity

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

Calling a new Activity

Postby skul3r » Wed Nov 04, 2009 7:49 pm

Hi, I would like to know how to kill a Activity that called a new one...

I read in documentation that when you call a new Activity using startActivity, it keeps the old activity in a stack. How can I take that old activity out from the stack if I dont want it anymore?
skul3r
Freshman
Freshman
 
Posts: 8
Joined: Fri Jul 03, 2009 2:04 pm

Top

Postby Emmanuel7 » Thu Nov 05, 2009 12:48 am

Call finish just after you call the startActivity to start your second activity should do the trick !

Hope it helps,
Emmanuel7
Senior Developer
Senior Developer
 
Posts: 164
Joined: Fri Dec 12, 2008 2:17 am
Location: Paris

Postby skul3r » Thu Nov 05, 2009 12:54 pm

Emmanuel7 wrote:Call finish just after you call the startActivity to start your second activity should do the trick !

Hope it helps,


Thank you!
skul3r
Freshman
Freshman
 
Posts: 8
Joined: Fri Jul 03, 2009 2:04 pm

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: No registered users and 8 guests