I agree with hackbod that the Application is probably the wrong place to put a user notification on any sort - I had just picked up on the general issue of doing something at application start. If you are after the status of the location provider you might want to implement the LocationListener onStatusChanged() method, which will give you timely notifications of provider change (e.g. GPS enabled)
> how do i make the custom application avaiable in the manifest? Do you have any examples? >> You will need to create a derived class and declare it in the manifest, >> e.g.: >> <application android:name="MyApplication" android:icon="@drawable/icon" >> android:label="@string/app_name"> Ludwig 2008/10/29 zl25drexel <[EMAIL PROTECTED]> > > how do i make the custom application avaiable in the manifest? Do you > have any examples? > > On Oct 29, 11:55 am, Ludwig <[EMAIL PROTECTED]> wrote: > > Classes derived from Application have an onCreate() method that gets > called > > when the application (as opposed to any individual activity) gets > started. > > You will need to create a derived class and declare it in the manifest, > > e.g.: > > <application android:name="MyApplication" > android:icon="@drawable/icon" > > android:label="@string/app_name"> > > > > HTH > > Ludwig > > > > 2008/10/29 zl25drexel <[EMAIL PROTECTED]> > > > > > > > > > Hi all > > > > > My app has some logics to check the gps status and shows an message > > > when its disabled. Currently i put those logics in the onCreate() > > > method of my apps's main activity. However, it turns out that this > > > onCreate() method is called very frequently rather than once per > > > application startup. That makes the notification message quite > > > annoying. > > > > > Is there any life cycle call back method that is only call once on > > > application start up? > > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

