Hi,
something like this? :
startInfo = new ProcessStartInfo("mysecondapp.exe);
startInfo.Arguments = "param1 param2 param3";
startInfo.CreateNoWindow = true;
startInfo.UseShellExecute = false;
startInfo.RedirectStandardOutput = true;
startInfo.RedirectStandardError = true;
getpub = new Process();
getpub.StartInfo = startInfo;
getpub.Start();
getpub.WaitForExit();
Console.WriteLine(getpub.StandardOutput.ReadToEnd( ));
Or, you can start a second thread, which just reads the standard output
from the process and display it while the process is running.
Sunny
In article <40*********************@news.free.fr>,
mo*******@free.fr
says...
Hi,
here is my trouble:
I need to call 2 diff?rents processes in a same dos window,
the first one is needed for the 2nd, and I have to pass several different
arguments to the 2nd.
My problem is that there are as many dos windows as calls to
"myProcess.start()", and I don't know how to do ...
Anybody has an idea ?
Thanks in advance (and sorry for my bad English)