服务状态 State=Running
等待服务 ,直到停止
状态 State=Stop Pending,Started=True
状态 State=Stop Pending,Started=True
状态 State=Stop Pending,Started=True
状态 State=Stop Pending,Started=True
状态 State=Stop Pending,Started=True
状态 State=Stop Pending,Started=True
状态 State=Stop Pending,Started=True
状态 State=Stopped,Started=False
等待服务 ,直到启动成功
状态 State=Start Pending,Started=True
状态 State=Start Pending,Started=True
状态 State=Running,Started=True
Function RestartService(ServiceName As String, Optional strComputer As String = ".") As Boolean
**
end function
RestartService "MSSQL$SQLEXPRESS"
标签:状态,service,WINDOWS,Stop,Started,State,VB6,True,Pending
From: https://blog.csdn.net/xiaoyao961/article/details/139074013