Check out this discussion, it sounds similar to what you want to accomplish: http://groups.google.com/group/android-developers/browse_thread/thread/a6a2161fe6ec064f/1cb8a1ef843b0787
Specifically, check out FLAG_ACTIVITY_CLEAR_TOP at: http://developer.android.com/reference/android/content/Intent.html#FLAG_ACTIVITY_CLEAR_TOP Hope this helps! -- PJ On Nov 5, 4:48 pm, PJ <pjbar...@gmail.com> wrote: > finishActivity() is intended to be used to force-finish an activity, > *** from the same activity that started it ***. > So, if you want to force-finish Activity B, then I think Main Activity > is the only one that can do it via finishActivity(), because Main > Activity is the one that started it. > > However, I think there's a way for Activity C to terminate and to go > back directly to Main Activity and to ask Main Activity to destroy all > activities "above" it (B). Let me see if I can find that... > > -- PJ > > On Nov 5, 2:58 pm, Bob Cai <caibo...@gmail.com> wrote: > > > > > Hello, > > > In main Activity, I called startActivityForResult(intentB, 100) to start a > > new activity B, then in B, I called startActivity(intentC) to start another > > activity C. Lastly I wanted to call finishActivity(100) in C to close > > activity B, but seemed it was not successfully destoried(I can use BACK key > > to see it's still there.). > > > Anyone can give advice of this? > > > Thanks, > > Bob- Hide quoted text - > > - Show quoted text - -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en