Answer the question
In order to leave comments, you need to log in
A class that monitors the status of a process running/not running. Anyone know one that's ready?
Does anyone know a library / class that can monitor the state of a process in the system? Notify me when a process has finished and started, and with exactly the names I'm monitoring?
I tried this example: stackoverflow.com/a/1986856
Yes, only when the process is closed, it returns a non-full name. Killed an hour and a half while writing a normal convenient class and this nonsense broke everything.
Answer the question
In order to leave comments, you need to log in
winapi has functions EnumProcesses, OpenProcess with PROCESS_QUERY_INFORMATION, EnumProcessModules, GetModuleBaseName
In C# in Assembly: System. There is an internal static class NativeMethods (Microsoft.Win32.NativeMethods) where the calls to these functions are defined.
Only there is a feature of EnumProcesses, if it works on behalf of a 32-bit process, it will return a list of only 32-bit processes. In the 64 bit version - all.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question