Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/batch-file/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Batch file 用于执行多个任务的批处理文件_Batch File_Scheduled Tasks - Fatal编程技术网

Batch file 用于执行多个任务的批处理文件

Batch file 用于执行多个任务的批处理文件,batch-file,scheduled-tasks,Batch File,Scheduled Tasks,我是新来的,有个问题 如何编写批处理文件以执行以下多个任务: 关闭程序“A” 打开程序“B”10分钟 关闭程序“B” 开放式程序“A” 非常感谢。您可能想试试: @echo off %SystemRoot%\System32\taskkill.exe /IM A_process.exe start B_process.exe %SystemRoot%\System32\timeout.exe /T 600 /NOBREAK %SystemRoot%\System32\taskkill.exe /

我是新来的,有个问题

如何编写批处理文件以执行以下多个任务:

  • 关闭程序“A”
  • 打开程序“B”10分钟
  • 关闭程序“B”
  • 开放式程序“A”
  • 非常感谢。

    您可能想试试:

    @echo off
    %SystemRoot%\System32\taskkill.exe /IM A_process.exe
    start B_process.exe
    %SystemRoot%\System32\timeout.exe /T 600 /NOBREAK
    %SystemRoot%\System32\taskkill.exe /IM B_process.exe
    start A_process.exe
    exit