
CODE: [Copy to clipboard]strComputer="."
Set objWMIService=GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
Set colProcessList=objWMIService.ExecQuery("Select * from Win32_Process Where " & _
"Name='wscript.exe'")
MyPath=Wscript.ScriptFullName
For Each objProcess in colProcessList
If InStr(objProcess.CommandLine, MyPath) Then n=n+1
Next
If n>1 Then Wscript.Quit
Wscript.Echo "测试"
| 欢迎光临 中国DOS联盟论坛 (http://cndos.fam.cx/forum/) | Powered by Discuz! 2.5 |