vbscript - Non-Blocking Sleep in Vbs, while waiting for WScript.Shell -


i'm working vbs1, starting wscript.shell, starting vbs2.

vbs1 running in bigger context , need keep proccess running , working, while waiting result of vbs2 (about 20-60sec)

using sleep non-blocking in script, blocking proccess, need option.

here's code got far:

strfinalcommand = "wscript.exe " & cstr(scriptpath) & " " & cstr(strparams) set objshell = createobject("wscript.shell") set shellexec = objshell.exec(strfinalcommand)  hittimeout = false sleepcounter = 0 while shellexec.status = 0 'wshrunning     activesession.sleep 100   '--> on changing sleep-duration, please change multiplier in if below,     sleepcounter = sleepcounter + 1     if sleepcounter >= timeoutduration * 10 'timeoutduration * 2         hittimeout = true         shellexec.terminate         exit     end if loop set shellexec = nothing set objshell = nothing  if hittimeout = false     reportsuccess = true end if 

everything running fine regarding script, other actions running proccess blocked.

can suggest sleep, non-blocking?


Comments

Popular posts from this blog

Command prompt result in label. Python 2.7 -

javascript - How do I use URL parameters to change link href on page? -

amazon web services - AWS Route53 Trying To Get Site To Resolve To www -