Service.ServiceState Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the state of the SQL Server service, such as running, stopped, or paused.
public:
property Microsoft::SqlServer::Management::Smo::Wmi::ServiceState ServiceState { Microsoft::SqlServer::Management::Smo::Wmi::ServiceState get(); };
public Microsoft.SqlServer.Management.Smo.Wmi.ServiceState ServiceState { get; }
member this.ServiceState : Microsoft.SqlServer.Management.Smo.Wmi.ServiceState
Public ReadOnly Property ServiceState As ServiceState
Property Value
Microsoft.SqlServer.Management.Smo.Wmi.ServiceState
A Microsoft.SqlServer.Management.Smo.Wmi.ServiceState object value that specifies the state of the SQL Server service.
Examples
Managing Services and Network Settings by Using WMI Provider