How to close the command line window after running a batch file?

后端 未结 7 1004
余生分开走
余生分开走 2020-12-13 08:23

I\'ve got a batch file. After it finished running, i.e. all command lines have been executed, the cmd.exe window stays open. However, I\'d like to have it closed ri

7条回答
  •  轮回少年
    2020-12-13 09:22

    %Started Program or Command% | taskkill /F /IM cmd.exe

    Example:

    notepad.exe | taskkill /F /IM cmd.exe

提交回复
热议问题