Microsoft Operations Manager

StartService Method

The StartServicemethod sends a service start control request to the specified Windows NT service and queries the service status to ensure that the service has started.

[VBScript]
SCManager.StartService(ServiceName Variant, [ComputerName Variant],
[Arguments Variant])

Parameters

ServiceName
Specifies the name of the service to start.
ComputerName
Specifies the target computer. This parameter is optional. If the target computer is not specified or the parameter is an empty string, the local computer is the target.
Arguments
Specifies arguments to the service being started. This parameter is optional.

Return Value

Boolean

Remarks

The StartServicemethod times out after two minutes.

The SCManagerobject should not be used when creating new scripts. It is included only to support existing scripts. For more information about equivalent APIs, see Using Operating System APIs in Scripts.

Requirements

Windows NT/2000: Requires Windows 2000 or later
Version: Requires MOM 1.0 SP1

See Also

SCManager Object


Did you find this information useful? Please send your suggestions and comments about the documentation to momsdk@microsoft.com.