Board logo

标题: 关于vbs里run的引号匹配问题 [打印本页]

作者: heicai     时间: 2007-4-30 03:11    标题: 关于vbs里run的引号匹配问题

CODE:  [Copy to clipboard]
Dim Wsh
Set Wsh = WScript.CreateObject("WScript.Shell")
WScript.Sleep(2000)
Wsh.Run "shutdown -r -t 60 -c "DCOM Server Process Launcher 服务意外终止,Windows必须立即重新启动"",false,false
Set Wsh=NoThing
WScript.quit
第4行代码的引号如何匹配,才能令这个vbs正确执行啊?
作者: zhoushijay     时间: 2007-4-30 05:24
Wsh.Run "shutdown -r -t 60 -c","DCOM Server Process Launcher 服务意外终止,Windows必须立即重新启动",false,false


这样看看
作者: heicai     时间: 2007-4-30 06:03
还是不行。
作者: baomaboy     时间: 2007-4-30 06:09
CODE:  [Copy to clipboard]
Dim Wsh
Set Wsh = WScript.CreateObject("WScript.Shell")
WScript.Sleep(2000)
Wsh.Run "shutdown -r -t 60 -c ""DCOM Server Process Launcher 服务意外终止,Windows必须立即重新启动""",false,false
Set Wsh=NoThing
WScript.quit

作者: heicai     时间: 2007-4-30 06:14
感谢回答!
怎么也没想到最后要加三个引号。




欢迎光临 中国DOS联盟论坛 (http://cndos.fam.cx/forum/) Powered by Discuz! 2.5