Loading |
VBScript |
JavaScript |
Powershell |
Search Options: List the Results of the Last System RestoreContent of List the Results of the Last System Restore.vbsMD5 Hash: D35831CF5D604D3E1A32945F28093B8C |
||
' Description: Returns the results (failed, succeeded, interrupted) of the last system restore performed on a computer.
strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\default") Set objItem = objWMIService.Get("SystemRestore") errResults = objItem.GetLastRestoreStatus() Select Case errResults Case 0 strRestoreStatus = "The last restore failed." Case 1 strRestoreStatus = "The last restore was successful." Case 2 strRestoreStatus = "The last restore was interrupted." End Select Wscript.Echo strRestoreStatus | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |