I am currently using CreateProcess to launch multiple programs which are exterior to the parent program. Now however, I want to spawn multiple calls to a function within the parent program. Is this possible using 'CreateProcess()'?
Below is what I'm using now. The command line for the 'isql' program which I'm launching takes various parameters to read a file and execute its contents.
string CommandStr = "isql /U /P /S " + ServerName + " /d " + DatabaseName + " /n /i c:\\mydbscript.txt";
pRC = ExecuteAndWaitForCompletion(ComndArray);
The ComdnArray is then passed to CreateProcess().
The program I'm now working on (completely different) launches a function which establishes a remote connection. I want to call this function multiple times. Can CreateProcess() do this? If so, how would 'CommandStr'
be modified to do this. Let's call the function connect().
Any idea if multiple streams are an issue here?
Thanks for the help!