I am currently firing off a windows process using System.Diagnostics.Process and waiting for the process to complete before allowing the code to proceed. This is currently inefficient especially when I have 30 or 40 different process to fire off. I wouldn't want to run all of them at once but I would be ok with running five of them at a time.
The main requirement that I have is that I need to be able to know when all of the processes are completed. To accomplish this currently I am using an asynchronous web service call that runs the processes. When the web service call is completed I know that the all of the processes are finished.
So my question is can I run more than one process at a time and at the same time, know when all of them have completed, and keep the web service call from returning a response? If so, can you provide a simple example of how I might accomplish this.