Platform SDK: Web Telephony Engine |
You can control the Web telephony service by performing the operations described below. Note that the account used to log on to the WTE service must have administrator privileges.
There are several ways to perform the preceding operations:
The Computer Management application lets you perform the start, hard stop, hard pause, and resume operations.
To use Computer Management
The net utility lets you perform the start, hard stop and hard pause operations from the command line. To perform these operations, use one of the following commands.
net start mswtesrv net stop mswtesrv net pause mswtesrv
The SC.exe utility lets you perform the soft-pause and soft-stop operations, flush logging data to the log file, and reload (refresh) configuration parameters from the persistent storage. To perform these operations, use one of the following commands:
Soft pause: sc control mswtersv 128 Soft stop: sc control mswtesrv 129 Flush to the log file: sc control mswtesrv 130 Refresh from storage: sc control mswtesrv 131
Web telephony supports two private service-control values that you can use in an application to perform a soft-pause or soft-stop operation. These values are defined in the PrivateWTEControlsType enumeration.
To perform a soft pause, pass the wteServicePauseSoft service-control value to the ControlService function.
To perform a soft stop, pass the wteServiceStopSoft service-control value to the ControlService function. Web telephony responds by playing a shut-down announcement to alert each caller that the service is about to stop.
The ShutdownTime and ShutdownAnnouncement properties of the WTEApplication object specify the amount of time that calls are allowed to continue, and the text or wave file that Web telephony uses for the shutdown announcement. These properties can also be configured through the application's property sheet in the WTE administration tool.
Note that if the ShutdownTime property is set to zero, the soft stop behaves like a hard stop. Also, if the ShutdownTime property is set to -1, the time-out period is infinite; that is, if calls do not disconnect themselves, they will not be disconnected when the service is soft paused or soft stopped. After the ShutdownTime property is set to -1, the service will not pause or stop.