VBS结束所有指定进程- Dim objWMIService,colProcessList
- Set objWMIService = GetObject("winmgmts:\\.\root\cimv2") ' " . " 代表本机
-
- '把下面的 qq.exe 替换为你的进程名字
- Set colProcessList = objWMIService.ExecQuery("Select * from Win32_Process Where Name = 'qq.exe'")
- For Each objProcess in colProcessList
- objProcess.Terminate()
- Next
-
- Set objWMIService = Nothing
- set colProcessList = Nothing
复制代码
|