I wrote a program launching and monitoring and generally manage other programs. In the general case I prepare a System.Diagnostics.ProcessStartInfo
and invoke Process.Start
. Later I start one thread per program that's checking periodically the resulting Process
object.
For testing propuses I configured my programm on my Win 7 machine to launch and monitor some typical Windows tools: Notepad, Paint and the Calculator. That all worked fine.
On a Windows 10 machine however the calculator behaves differently. The process started by Process.Start immediately terminates, and there is no calc.exe child to my launcher, but a win32calc.exe child to explorer.exe. child to a non existing process, the process my launcher created.
Why is that? How do I get a handle to that? What would be a strategy to monitor programs started by my launcher, even if they choose to abandon their parent?