【发布时间】:2018-01-14 03:46:45
【问题描述】:
我目前有一个小脚本可以同时打开两个程序:
@echo off
start "" "D:\...\Hearthstone Beta Launcher.exe"
start "" "C:\...\Innkeeper.exe"
exit
这可行,但现在我还想在关闭炉石时退出 Innkeeper 进程。
但是,还有一个额外的困难:Hearthstone Beta Launcher.exe 实际上打开了第三个程序,battle.net 客户端,然后您可以通过它打开 Hearthstone.exe 本身。
所以本质上,我想修改批处理脚本以执行以下操作:
- 开始
Hearthstone Beta Launcher.exe - 开始
Innkeeper.exe - 等待
Hearthstone.exe打开 - 等待
Hearthstone.exe关闭 - 终止
Innkeeper.exe和battle.net客户端 - 光荣地自毁(又名
exit)
这样的监听是否可以批量进行,如果可以,怎么做?
(我也会对使用批处理以外的解决方案感到满意。)
【问题讨论】:
标签: windows batch-file