0

CreateObject("Wscript.Shell").Run "timeout /t 10 /nobreak && cd C:/Files/MyApp/ && start app.exe", 1, False

This is my very simple script: an attempt to initiate a program with a timeout.

But I seem to be getting an syntax error (the cmd screen which flashes very fast says that I can only use the timeout once - I'm already only using it once...)

PS: when I paste the command directly into cmd it works correctly.

1 Answer 1

0

Invisible program caller with delay is now working. I took off the timeout from the console arguments and replaced it for a typical VBS delay. wscript.sleep 10000 WScript.CreateObject("WScript.Shell").Run "cmd /K CD /D ""c:/Files/myApp/"" && start App.exe", 0, False

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .