Android Check GPS is Enabled or Not

In android, we can easily check whether GPS is enabled in device or not using LocationManager.
Here is a simple program to Check.
GPS Enabled or Not :-
Add the below user permission line in AndroidManifest.xml to Access Location
[sourcecode language="xml"]
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
Your java class file sgould be
[sourcecode language="java"]
public class ExampleApp extends Activity {
/** Called when the activity is first created.

Syndicate content