I found how reboot a PC, by the command "GetObject("winMgmts:{(Shutdown)}\\"
& p_strComputerName)" but why "{(shutdown)}".
For me i just need this code without "{(shutdown)}".
p_objWbemRoot = GetObject("winMgmts:\\" & p_strComputerName)
p_colComputers = p_objWbemRoot.ExecQuery("Select * from
Win32_OperatingSystem")
For Each p_objComputer In p_colComputers
p_lngRtn = p_objComputer.Win32Shutdown(p_lngIndex)
Next
If someone can help me, thanks
eric
--
This posting is provided "As Is" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
<eric> wrote in message news:efJ211bqCHA.1624@TK2MSFTNGP10...