Wednesday, April 1, 2015

Waiting for a process which creates another process

Hi,


In my code, I am waiting for the Updater.exe to finish and do some custom tasks after it completes successfully (using Process.WaitForExit()). But the Updater.exe downloads the binary and creates another process (Installer) and wait till it finishes and will end once the installer ends. For me, as I am using Process.WaitForExit(), I am getting the process exit code (0) from Updater.exe once it completes the download of binary (before actually the installation happens). I need to wait till both these processes complete their job and I need to catch the error codes as well. How can I implement this?


Thanks in advance.




Thanks Prasad


No comments:

Post a Comment