Hello,
         I have problem in my application when i press exit i try to close
all my activity but GPS running so how i disable GPS status and close my
application (because when i go to Application manager it's show mw my
application running and force close button enable)

my code to close all activity are..


android.os.Process.killProcess(android.os.Process.myPid());
System.exit(0);

killThisPackageIfRunning(HomePage.this,getApplication().getPackageName());
finish();

public static void killThisPackageIfRunning(final Context context, String
packageName){
        ActivityManager activityManager =
(ActivityManager)context.getSystemService(Context.ACTIVITY_SERVICE);
        activityManager.killBackgroundProcesses(packageName);
    }





-- 

Thanks and Regards,

Ankit Kasliwal
[email protected]
+91-9300-940-136

-- 
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

Reply via email to