[python-win32] Wait for process to be started

Ram Rachum ram at rachum.com
Wed Apr 25 08:26:37 EDT 2018


 I'm writing a Python program on Windows 7. I want the program to patiently
wait for a process to be started that has a certain name, and then do an
action after it was started.

I can easily write the program using polling, i.e. checking every second
whether the process is active, but I want to be more efficient and wait on
the system event that is generated when a process is started. Is that
possible?

I was told that the `wmi` module is the way to go, but does anyone know how
to make it do what I described above?


Thanks,
Ram.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-win32/attachments/20180425/90cea8cd/attachment.html>


More information about the python-win32 mailing list