wait for the second VB script untill ended from primary VB script
Hi I have VB script that run second VB script The second VB script ask some questions from the input box My problem is that “MyShell.Run” not wait until SecondVBscript.vbs will ended And the Other VB syntax run immodestly also
Need to wait for MyShell.Run process ended and then 开发者_高级运维perform the Other VB syntax How can I do that?
Set MyShell = Wscript.CreateObject("WScript.Shell")
MyShell.Run " C:\Program Files\SecondVBscript.vbs"
Set MyShell = Nothing
Other VB syntax
Use Exec.
You need to pass an additional argument --
MyShell.Run "C:\Program Files\SecondVBscript.vbs", 1, true
Already answered @ Wait for the second VBScript script until ended from primary VBScript script
精彩评论