日期:2014-05-17  浏览次数:21015 次

如何写bat命令启动可执行文件?
请教各位高手,例如我想启动迅雷,但我不想通过双击迅雷的可执行文件打开迅雷。我想尝试写个bat命令去启动它,可我对bat命令不怎么熟悉,请问各位大虾,我该怎么写这个bat命令???

------解决方案--------------------
BatchFile code
start "C:\Program Files\Thunder Network\Thunder\thunder.exe"

------解决方案--------------------
test.bat

BatchFile code

start "C:\Program Files\Thunder Network\Thunder\thunder.exe"

------解决方案--------------------
test.bat

BatchFile code

start "" "C:\Program Files\Thunder Network\Thunder\thunder.exe"

------解决方案--------------------
test.bat

BatchFile code
@echo off
set /p "input=[Y:启动|N:关闭]"
if /i "%input%" equ "y" (
    start "" "C:\Program Files\Thunder Network\Thunder\thunder.exe"
) else if /i "%input%" equ "n" (
    taskkill /f /imthunder.exe
)

------解决方案--------------------
最近贴代码老贴错

test.bat

BatchFile code
@echo off
set /p "input=[Y:启动|N:关闭]"
if /i "%input%" equ "y" (
    start "" "C:\Program Files\Thunder Network\Thunder\thunder.exe"
) else if /i "%input%" equ "n" (
    taskkill /f /im thunder.exe
)