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

后端 未结 7 1028
余生分开走
余生分开走 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:01

    For closing cmd window, especially after ending weblogic or JBOSS app servers console with Ctrl+C, I'm using 'call' command instead of 'start' in my batch files. My startWLS.cmd file then looks like:

    call [BEA_HOME]\user_projects\domains\test_domain\startWebLogic.cmd
    

    After Ctrl+C(and 'Y' answer) cmd window is automatically closed.

提交回复
热议问题