close a particular command prompt

后端 未结 3 1960
礼貌的吻别
礼貌的吻别 2021-01-20 02:29

I have opened a commnad prompt using java program and another command prompt manually. Now my requirement is that i need to close the command prompt that i have opened by ja

3条回答
  •  迷失自我
    2021-01-20 03:19

    if you're using Runtime.getRuntime().exec(), it returns a Process object. You should hold on to that and call Process.destroy() when you're done.

提交回复
热议问题