标签: vbscript windows-7 windows-10
我对此有几个问题。 1)是否有任何原因WshShell.sleep在Windows 10上不起作用? 2)有哪些替代方案?它们也需要与Windows 7兼容。
set WshShell = CreateObject("Wscript.Shell") WshShell.sleep 10000
创建以下错误 http://prntscr.com/86o9ml 提前谢谢。
答案 0 :(得分:3)
Wscript.Shell不包含睡眠方法。你想要Wscript.Sleep。
Wscript.Shell
Wscript.Sleep
Wscript.sleep 10000
Wscript对象已经存在,无需创建它。
Wscript