I asked a similar question to this earlier this week but I\'m still not understanding how to get a list of all installed applications and then pick one to run.
I\'v
private static boolean isThisASystemPackage(Context context, PackageInfo packageInfo ) {
try {
PackageInfo sys = context.getPackageManager().getPackageInfo("android", PackageManager.GET_SIGNATURES);
return (packageInfo != null && packageInfo.signatures != null &&
sys.signatures[0].equals(packageInfo.signatures[0]));
} catch (NameNotFoundException e) {
return false;
}
}