Loading |
VBScript |
JavaScript |
Powershell |
Search Options: Modify Service Error Control CodesContent of Modify Service Error Control Codes.vbsMD5 Hash: 0A9CDD57F69FDE3DCF90B7232C7EB8B9 |
||
' Description: Configures all auto-start services to issue an alert if the service fails during startup.
Const NORMAL_ERROR_CONTROL = 2 strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2") Set colServiceList = objWMIService.ExecQuery _ ("Select * from Win32_Service where ErrorControl = 'Ignore'") For Each objService in colServiceList errReturn = objService.Change( , , , NORMAL_ERROR_CONTROL) Next | ||
© 2008 - 2013 Boris Toll :: Scripts available: 6.481 :: :: scriptbox.toll.at :: :: powered by www.toll.at :: |