Presumable the user has disabled them for good reason, and apps should not toggle them behind the users back.
You could show a dialog to the user, explaining that you'd like location enabled, and then launch into the Settings app using the "android.settings.LOCATION_SOURCE_SETTINGS" Intent. j On Fri, May 29, 2009 at 6:06 PM, Will <[email protected]> wrote: > > How do I enable/disable GPS and Wifi providers? I check to see if they > are enabled by using this code: > > locationManager.isProviderEnabled("gps") > locationManager.isProviderEnabled("network") > > If both are false, I'd like to turn enable the GPS provider and/or the > Network provider so that the above checks would return true. Is this > possible? If so, what permissions does it require? > > I've searched the API and can't find any solutions. Thanks for any > help in advance. > > > > > -- Jeff Sharkey [email protected] --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

