Finish is the recommended way of closing Activites. You should be using only
this to exit your Activities. The OS will take care of the Application as a
whole.


Kumar Bibek
http://techdroid.kbeanie.com
http://www.kbeanie.com



On Tue, Jan 11, 2011 at 7:45 AM, jotobjects <[email protected]> wrote:

> On Jan 10, 11:17 am, Dianne Hackborn <[email protected]> wrote:
> > On Mon, Jan 10, 2011 at 3:27 AM, 20plus10 30 <[email protected]> wrote:
> > > It wil stop the application ttally.
> > > It kills its own proccess.
> >
> > It does kill the process, but that does not stop the application totally.
> >  Don't use this.
> >
> In the usual case of the Application only having one Process what part
> of the application would not be stopped?
>
> It seems that finish() is the better way so that the Android platform
> can manage the process lifecycle, but finish() only stops one Activity
> not all the components of the Application.  The
> FLAG_ACTIVITY_CLEAR_TOP from the launch Activity will stop the
> Activities (if there is not more than one Task involved) but not the
> Service components.  It comes back to designing Apps that do not need
> to be stopped.
>
> The real world case I encountered recently was an App that required
> registration and exited automatically if the user did not complete the
> registration steps.  This was done with finish().  Is there any better
> way to accomplish that kind of requirement?
>
>
> > --
> > Dianne Hackborn
> > Android framework engineer
> > [email protected]
> >
> > Note: please don't send private questions to me, as I don't have time to
> > provide private support, and so won't reply to such e-mails.  All such
> > questions should be posted on public forums, where I and others can see
> and
> > answer them.
>
> --
> 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]<android-developers%[email protected]>
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
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

Reply via email to