Using Google API for GPS
Using Google API for GPS This post will show you how implement a Google Service Step 1 Enable the service on AndroidManifest.xml <service android:name="mx.com.yourAppName.Globals.GpsService"> </service> Step 2 Add this class. This class can mantain service on and show an alert window if the GPS service in off and send to activate service. package mx.com. yourAppName .Globals; import android.Manifest; import android.app.Activity; import android.app.AlertDialog; import android.app.Service; import android.content.Context; import android.content.DialogInterface; import android.content.Intent; import android.content.pm.PackageManager; import android.location.Location; import android.location.LocationManager; import android.os.Build; import android.os.Bundle; import android.os.Handler; import android.os.IBinder; import android.provider.Settings; import android.support.annotatio...