Can an Android application know when another Android application is running?

You can get a list of installed applications by using the PacketManager Code from here : public class AppList extends Activity { @Override public void onCreate(Bundle savedInstanceState) { super. OnCreate(savedInstanceState); PackageManager pm = this. GetPackageManager(); Intent intent = new Intent(Intent.

ACTION_MAIN, null); intent. AddCategory(Intent. CATEGORY_LAUNCHER); List list = pm.

QueryIntentActivities(intent, PackageManager. PERMISSION_GRANTED); for (ResolveInfo rInfo : list) { Log. W(“Installed Applications�

, rInfo.activityInfo. ApplicationInfo . LoadLabel(pm).toString()); } } To see the currently running apps, you can use the ActivityManager.

You can get a list of installed applications by using the PacketManager. Code from here: public class AppList extends Activity { @Override public void onCreate(Bundle savedInstanceState) { super. OnCreate(savedInstanceState); PackageManager pm = this.

GetPackageManager(); Intent intent = new Intent(Intent. ACTION_MAIN, null); intent. AddCategory(Intent.

CATEGORY_LAUNCHER); List list = pm. QueryIntentActivities(intent, PackageManager. PERMISSION_GRANTED); for (ResolveInfo rInfo : list) { Log.

W(“Installed Applications� , rInfo.activityInfo. ApplicationInfo .

LoadLabel(pm).toString()); } } To see the currently running apps, you can use the ActivityManager.

Thanks for the answer. Very exciting. – Will Merydith May 20 at 17:13.

This post explains how you can achieve that functionality in a generic way. This post and this one have snippets of an Activity that lists the running applications, using ActivityManager's getRunningAppProcesses(). This post explains how to get a list of all installed applications and then to choose one to run.

It should be added that you'll need to add a permission to your manifest to use getRunningTasks() or getRecentTasks(). Android.permission. GET_TASKS to be exact.

– Maximus May 19 at 20:21.

Chris Kimber, I would suggest you look at getting some external expertise in for the Android application. We've yet to see a functional iPlayer app when compared to the one man coded (and much missed) beebPlayer. Looking at the help page (http://iplayerhelp.external.bbc.co.uk/help/playing_radio_progs/mobileradio), it's clear that there's some worrying misconceptions about the platform.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions