IADsService Property: ErrorControl

Property Name
ErrorControl

Property Type
enumErrorControl

Description
Gets and sets the action to be taken if the service fails on startup. The following values are supported:

Value

Description

ERRORTYPE_IGNORE = 0 

Logs the error but continues the startup operation

ERRORTYPE_NORMAL = 1 

Logs the error, puts up a message box pop up and continues the startup operation

ERRORTYPE_SEVERE = 2  

Logs the error and tries to start the service with the last known good configuration. Otherwise, fails to start the service

ERRORTYPE_CRITICAL = 3 

Logs the error if possible. If the last known good configuration is being started then the startup operation fails. Otherwise, the system is restarted with the last known good configuration

Example

Dim serobj As IADsService
'Get the object of the service
Set serobj = GetObject("NTDS://MSFT/MOON/Messenger")
'Get the service error control property of the service
Debug.Print serobj.ErrorControl
'set the error control property to critical
serobj.ErrorControl = ERRORTYPE_CRITICAL
serobj.SetInfo

 

See Also: