`
阿尔萨斯
  • 浏览: 4200241 次
社区版块
存档分类
最新评论

A scripting for rebooting system

 
阅读更多
<iframe align="center" marginwidth="0" marginheight="0" src="http://www.zealware.com/csdnblog336280.html" frameborder="0" width="336" scrolling="no" height="280"></iframe>
strComputer="."
SetobjWMIService=GetObject("winmgmts:"_
&"{impersonationLevel=impersonate,(Shutdown)}!/"&strComputer&" ootcimv2")
SetcolOperatingSystems=objWMIService.ExecQuery_
(
"Select*fromWin32_OperatingSystem")
ForEachobjOperatingSystemincolOperatingSystems
ObjOperatingSystem.Reboot()
Next



分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics