@echo off:1tasklist | find "notepad.exe" >>c:\notepad.luoweiif exist c:\notepad.luowei taskkill /f /im notepad.exeping 127.1 -n 20 >nul 2>nulgoto 1
每隔20秒自动检测进程列表,自动关闭notepad.exe。