Get the "Running Program List" in C# Compact Framework

Within a C# application running on a Pocket PC -- I would like to get a listing of the currently running applications -- i.e., the same ones that show up in the "Runnig Program List" under the "Settings"->"Memory".

Just need to stick the results into arraylist or the like -- and look for a specific application name.  Then if it's not running -- need to launch the application.
Who is Participating?
God_AresConnect With a Mentor Commented:
I think you going to thank me for this one,...

ever head of opennetcf? it's a downloadable libary. I suggest you serious look at it,.. (soooo trying no to use caps,..)

with use of the code submitted by NTAC + few mods = success

regards Floris Briolas
Here is something that mihgt do what you want:

                  Process[] pArray = System.Diagnostics.Process.GetProcesses();

                  bool startProc = true;
                  foreach ( Process proc in pArray)
                        if( proc.ToString().equals(yourNameYouWantToCheck) )
                              startProc = false;

                  if( startProc )
The Process.GetProcesses() willl return a list of running procs.  Then you can check it from there, and if not found--it will start the application you want.  Good luck on your program.
LanceWLarsenAuthor Commented:
Hmm... tried that -- but seems as if the System.Diagnostics.Process method does not exist in the Compact Framework... ideas?  Is there an alternate way to access the processes in the Compact Famework?

Thanks tons...
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.