IWSDDeviceHost::RetireService method (wsdhost.h)
Unregisters a service object that was registered using RegisterService and removes the service from the device host metadata.
Syntax
HRESULT RetireService(
[in] LPCWSTR pszServiceId
);
Parameters
[in] pszServiceId
The ID of the service to be removed.
Return value
Possible return values include, but are not limited to, the following:
Return code | Description |
---|---|
|
Method completed successfully. |
|
pszServiceId is NULL. |
|
The length in characters of pszServiceId exceeds WSD_MAX_TEXT_LENGTH (8192), or pszServiceId was not found in the list of registered services. |
|
The method failed. It may have failed because the host has not been initialized. Call Init to initialize a device host. |
Remarks
The device host releases its reference to the service object after the service is unregistered. The service object will not receive callbacks after RetireService has completed.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows Vista [desktop apps only] |
Minimum supported server | Windows Server 2008 [desktop apps only] |
Target Platform | Windows |
Header | wsdhost.h (include Wsdapi.h) |
DLL | Wsdapi.dll |