- desiredStatus
- The status to wait for.
- timeout
- A T:TimeSpan object specifying the amount of time to wait for the service to reach the specified status.
| Visual Basic (Declaration) | |
|---|---|
Public Sub WaitForStatus( _ ByVal desiredStatus As ServiceControllerStatus, _ ByVal timeout As TimeSpan _ ) | |
| Visual Basic (Usage) | Copy Code |
|---|---|
Dim instance As DicomService Dim desiredStatus As ServiceControllerStatus Dim timeout As TimeSpan instance.WaitForStatus(desiredStatus, timeout) | |
| C# | |
|---|---|
public void WaitForStatus( ServiceControllerStatus desiredStatus, TimeSpan timeout ) | |
| Managed Extensions for C++ | |
|---|---|
public: void WaitForStatus( ServiceControllerStatus desiredStatus, TimeSpan timeout ) | |
| C++/CLI | |
|---|---|
public: void WaitForStatus( ServiceControllerStatus desiredStatus, TimeSpan timeout ) | |
Parameters
- desiredStatus
- The status to wait for.
- timeout
- A T:TimeSpan object specifying the amount of time to wait for the service to reach the specified status.
For an example refer to InstallService
This is a blocking operation.
Target Platforms: Microsoft .NET Framework 2.0, Windows 2000, Windows XP, Windows Server 2003 family, Windows Server 2008 family, Windows Vista, Windows 7
Copy Code