I assume this carries on from your earlier question about delaying
tasks in an onCreate()?

It is technically possible to move your intensive code into a
"Service" and have it start when the phone boots up, but bear in mind
that this is an unpopular method, as users will find their phones
become sluggish whilst your app does all it's processing work in the
background.

My recommendation is to try and optimise your app a bit better.
Otherwise you will get low ratings on the market and lots of refunds
(if you plan to sell it). Some suggestions:

- Take a look at some of the suggestions on your previous thread
- Use a progress dialog when slow loading operations are occurring (it
makes a BIG difference when the user can see that something is busy)
- Delay some of your processing until the user does something (like
clicking on a tab)
- Cache some of your processed data, either in a database or a file,
so you don't have as much to do the next time the app is loaded

There are plenty of other things you can do, some thought and research
should . Really, launching stuff in the background should be avoided
as much as possible, mobile devices have very limited resources and
your app will have a negative impact on the phone's responsiveness.

On Thu, Jan 7, 2010 at 3:48 PM, Michael Dorin <[email protected]> wrote:
> Can I launch an activity and have it go strait into the background without
> the user seeing it, until they select to launch it themselves?
>
> Basically I have an application that takes a long time to start the first 
> time,
> but is super snappy after that.
>
> -Mike
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow at
> http://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/android-beginners?hl=en
>
>
-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en

Reply via email to