all groups > c# > february 2006 >
You're in the

c#

group:

Run vbs from C#


Run vbs from C# MAF
2/22/2006 9:09:17 PM
c#:
I need to find a way to run a vbs on the same thread that I am currently on.

Here is the code I have now and this causes the scripts to be run out of
order. I want to have the application wait until the process is finished
before executing the next script.
Process scriptConsoleProcess;


scriptConsoleProcess = new Process();

scriptConsoleProcess.StartInfo.FileName = scriptPath;

scriptConsoleProcess.StartInfo.UseShellExecute = true;

scriptConsoleProcess.StartInfo.CreateNoWindow = true;

scriptConsoleProcess.Start();

Re: Run vbs from C# Bob Grommes
2/26/2006 1:01:20 PM
After you start the process:

while (scriptConsoleProcess.HasExited == false) {
// do nothing ... or maybe exit if too much
// time has passed.
}


[quoted text, click to view]
AddThis Social Bookmark Button