I have a Main Activity, then a ListActivity to select an item to show, and then a third activity to show selected item. When user push back button, I want him to go back to main activity, not the listActivity.
How can I do that?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There are a few ways to do this. Probably the simplest is to call
in the ListActivity immediately after you call
startActivityto start the third activity.This will achieve what you want with no overriding of the back button required.