Differences

This shows you the differences between the selected revisions of the page.

2009-07-08 2009-11-21
no summary (78.106.160.43) fix waiting loop (martin)
Line 42: Line 42:
while (exec.Status == 0) while (exec.Status == 0)
{ {
-·····WScript.Sleep(100);+····WScript.Sleep(100);
} }
</code> </code>
-If you want to see WinSCP output replace the trailing ''while'' statement with:+If you want to see WinSCP output modify the trailing ''while'' as:
<code javascript> <code javascript>
-// wait until the script finishes +// wait until it finishes 
-while (!exec.StdOut.AtEndOfStream)+while (exec.Status == 0)
{ {
 +    WScript.Sleep(100);
    WScript.Echo(exec.StdOut.ReadAll());     WScript.Echo(exec.StdOut.ReadAll());
} }

Last modified: by martin