Saturday, 10 August 2013

How to Restart the PC Using QTP

Use WMI to restart PC Dim OpSysSet Set OpSysSet = GetObject("winmgmts:{(Shutdown)}//./root/cimv2").ExecQuery("select * from   Win32_OperatingSystem where Primary=true") for each OpSys in OpSysSet   OpSys.Reboot()

No comments:

Post a Comment