-
How can you find out what the process ID of a program is
from within a VB6 program running in a Windows NT
environment. I am writing a VB program that will need
to find out how long certain processes are running and
if they have been runnning too long I need to get their
pid's and kill those processes.
Please help!
Manuel
-
You might find a suitable API code here: http://www.mvps.org/vb/ (perhaps Shell32).
I think using :
Private Declare Function GetCurrentProcessId Lib "kernel32" () As Long will give the current PID, so may have to use another API call to loop through all open processes.
VB6 Enterpise has a Process Viewer tool, can this be used in some way to return all open Process PIDs? I will look into it.
-