Monitor multiple variable amounts of processes' start and exit

Posted by ron975 on Stack Overflow See other posts from Stack Overflow or by ron975
Published on 2012-11-14T04:22:30Z Indexed on 2012/11/14 5:00 UTC
Read the original article Hit count: 127

Filed under:
|
|
|

I need some code to monitor the start and exit of processes. For example, assume I have a config file with 3 processe names, lets say, foo.exe, bar.exe and abc.exe. How I imagine this be done would be to create 3 threads and somehow listen to each process individually with a timer in each thread, and then do something afterwards. However, I would need to dynamically create threads and timers, as the config file is meant to be modifiable.

I can work with VB.NET or C# Code. Thanks.

© Stack Overflow or respective owner

Related posts about c#

Related posts about vb.net