批处理文件杀死并重新启动没有响应的程序 [英] Batch file to kill and restart not responding program

查看:132
本文介绍了批处理文件杀死并重新启动没有响应的程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在运行一个程序(Win7),该程序有时会卡住并且没有响应.

I am running a program (Win7) which sometimes gets stuck and not responding.

只需要您的帮助来编写可以检查程序状态的批处理过程,如果它没有响应,请关闭并再次打开它

Just wanted your help to write batch process that can check the program status and if it's Not responding then close and open it again

推荐答案

测试一下:仅在任务没有响应且已被强制终止时才重新启动be2beat.

Test this: it should only relaunch be2beat when the task is not responding, and has been killed forcefully.

@echo off 
taskkill /im "Be2Beat.exe" /fi "STATUS eq NOT RESPONDING" /f >nul && start "" "C:\Program Files (x86)\Be2Beat\Be2Beat Multimedia Platform\Be2Beat.exe"

这篇关于批处理文件杀死并重新启动没有响应的程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆