Find a system process by it's name (and check whether or not it is running)

promalley2

New Member
Joined
Nov 16, 2009
Messages
24
Greetings!<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:eek:ffice:eek:ffice" /><o:p></o:p>
<o:p> </o:p>
I’m creating a number of routines and functions that work in conjunction with my CAD software’s VB API. In order for the VB API to function properly, it requires two environment variables with specific names and one system process to be running (which is started when a new asynchronous connection and session is established between an application and the CAD software). I’ve been able to successfully check whether the two environment variables exist by calling them by their specific names, but I’m having trouble figuring out how to identify if the unique system process is running. For this discussion, let’s call the name of the unique process “namespc.”<o:p></o:p>
<o:p> </o:p>
In my research prior to posting, I haven’t been able to locate a way to look at the list of system processes running outside of the windows API—which is not something I’m familiar with at all, but I’m open to learn if someone can point me to the right resources. But I’m looking for suggestions as to what ways there are to examine the list of system processes and which one might be considered “the best.”<o:p></o:p>
<o:p> </o:p>
Again, all I’m looking to do here is look at the list of system processes by name and see if “namespc” is there. And if “namespc” is contained in the list of system processes, I’d like to check to see if it’s running (or is it the case where if the process is in the list, then it is considered to be running?).<o:p></o:p>
<o:p> </o:p>
Thanks in advance for taking the time!<o:p></o:p>
<o:p> </o:p>
<o:p> </o:p>
--PRO<o:p></o:p>
 
Glad you found something.

You might also want to look at Windows Powershell.

I only just found that when I fired up an old machine that I'd forgotten about.

Checked on my current machine and it was there too.

Perhaps not much use for what you want to do, I can seem to find much about integrating with other apps or using VBA.

Mind you it did find something about scripting WMI using Powershell.
 
Upvote 0

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.

Forum statistics

Threads
1,216,006
Messages
6,128,236
Members
449,435
Latest member
Jahmia0616

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top