[color=red]前提:F:/workspace/test目录下有My.exe依赖的配置[/color]
1.如果test.vbs也在F:/workspace/test目录下
test.vbs文件内容如下:
或者
[color=red]计划任务里指向该test.vbs文件[/color]
2.如果test.vbs不在F:/workspace/test目录下,则需要一个bat文件转(假如叫test.bat)
test.vbs文件内容如下(去执行bat):
test.bat:
[color=red]计划任务里指向该test.vbs文件[/color]
1.如果test.vbs也在F:/workspace/test目录下
test.vbs文件内容如下:
Dim Wsh
Set Wsh = WScript.CreateObject("WScript.Shell")
WScript.Sleep 5000
Wsh.Run "F:/workspace/test/My.exe",,True
WScript.quit
或者
Dim Wsh
Set Wsh = WScript.CreateObject("WScript.Shell")
WScript.Sleep 5000
Wsh.Run "My.exe",,True
WScript.quit
[color=red]计划任务里指向该test.vbs文件[/color]
2.如果test.vbs不在F:/workspace/test目录下,则需要一个bat文件转(假如叫test.bat)
test.vbs文件内容如下(去执行bat):
Dim Wsh
Set Wsh = WScript.CreateObject("WScript.Shell")
WScript.Sleep 5000
Wsh.Run "F:/workspace/test.bat",,True
WScript.quit
test.bat:
cd\
F:
cd F:\workspace\test
My.exe
[color=red]计划任务里指向该test.vbs文件[/color]