have some trouble stopping an app that I start with startActivity. Here is how I start it:
Intent theApp = new Intent();
theApp = getPackageManager().getLaunchIntentForPackage(thePackageName);
theApp.addCategory(Intent.CATEGORY_LAUNCHER);
theApp.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
getApplicationContext().startActivity(theApp);
after it has ran for awhile, im trying to stop it like this:
if(stopService(theApp))
Log.d(TAG,"Stopped app successfully!");
else
Log.d(TAG,"Failed to stop the app!");
Any ideas why this isnt working? Thanks in advance for your help