But he didn't say he wanted to destroy A. He said "A should be sent to background[sic]". So your proposal, good though it is, might not be the right answer. That is why I am saying he has to study http://developer.android.com/guide/topics/fundamentals.html#lcycles so that he has the background to no longer confuse 1) what he wants to do with 2) how it is best done. For it is clear that he really does not understand how to design Activities to work well with Android lifecycle management. He is asking for how to do the wrong things.
After all, maybe he should go ahead and do it your way, destroying A. In fact, this is likely, even if it does force him to rethink his design. But if he really does require A to go to the background, then he will have to start up B some other way, such as sending it an Intent. But then when SHOULD he destroy A? It has to be done sometime, but we can't say when. If he doesn't have a good answer to this question either, then that is another strong hint that he should go ahead and do it your way, destroying A and recreating it when needed. On Sep 8, 8:08 am, Mark Murphy <[email protected]> wrote: > On Wed, Sep 8, 2010 at 11:03 AM, Ajmer singh <[email protected]> wrote: > > I have another question regarding that, How can i put the already running > > activity in the background to the foreground, > > For example : if i have started Activity A then i started other Activity B > > Then Activity A should be sent to background Then how can i bring back > > Activity A to foreground(With using the Back button). > > Call finish(), which will destroy B and bring A back to the foreground. > > -- > Mark Murphy (a Commons > Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy > > Android Training in London:http://skillsmatter.com/go/os-mobile-server -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

