您的位置:首页 > 其它

Windows批处理:自动开关程序

2015-09-01 16:10 543 查看
公司有台14年组装的PC,时常无故重启,所以编写了个然并卵的批处理来测试稳定性。

打开程序.bat

@echo off
title Start Software
color 2F

:0
"C:\Program Files\Adobe\Adobe Photoshop CS5 (64 Bit)\Photoshop.exe"
ping -n 6 127.0.0.1>%temp%\1.tmp
"C:\Program Files (x86)\Adobe\Adobe Dreamweaver CS5\Dreamweaver.exe"
ping -n 6 127.0.0.1>%temp%\1.tmp
"C:\Program Files (x86)\Adobe\Adobe Flash CS5\Flash.exe"
goto 0


关闭程序.bat

@echo off
title Kill Software
color 2F

:0
taskkill /f /im Photoshop.exe
ping -n 8 127.0.0.1>%temp%\1.tmp
taskkill /f /im Dreamweaver.exe
ping -n 8 127.0.0.1>%temp%\1.tmp
taskkill /f /im Flash.exe
ping -n 8 127.0.0.1>%temp%\1.tmp
goto 0




本文出自 “运维菜鸟.log” 博客,谢绝转载!
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: