Share via


IWSDDeviceHost::SetServiceDiscoverable (Compact 2013)

3/26/2014

This method controls whether or not the service is advertised using WS-Discovery.

Syntax

HRESULT SetServiceDiscoverable(
  const WCHAR* pszServiceId,
  BOOL fDiscoverable
);

Parameters

  • pszServiceId
    [in] The ID for the service.
  • fDiscoverable
    [in] TRUE if the service can be found using WS-Discovery, FALSE if the service is not visible to WS-Discovery.

Return Value

The following table shows the possible error code return values.

Error code

Description

S_OK

This method completed successfully.

E_INVALIDARG

pszServiceId is NULL, the length in characters of pszServiceId exceeds WSD_MAX_TEXT_LENGTH (8192), or pszServiceId does not correspond to a registered service.

Requirements

Header

wsdapi.h

Library

wsdapi.lib

See Also

Reference

IWSDDeviceHost
Web Services on Devices Interfaces