I have the crazy notion that in the following code
VBScript should
execute "write" and then wait until "write" is closed.
But the box created by the <WScript.Echo "RC = " & rc>-statement pops up
before "write" does.
Have I misunderstood the meaning of the [bWaitOnReturn] parameter?
Is there another way to do it?
Thanks in advance for any help!
Anders Tobiasen
Dim WshShell, rc
set WshShell = WScript.CreateObject("WScript.Shell")
rc = RunIt("write " & Wscript.ScriptFullName)
WScript.Echo "RC = " & rc
Function RunIt(Prog)
RunIt = WshShell.Run(Prog, 1, TRUE)
end function