GattDeviceService.GetDeviceSelectorFromShortId(UInt16) Method

Definition

Creates a suitable AQS Filter string for use with the CreateWatcher method, from a 16-bit Bluetooth GATT Service UUID.

Important

The GetDeviceSelectorFromShortId API is deprecated, and it may not be available in future versions of Windows. Instead, use GetDeviceSelectorFromUuid.

public:
 static Platform::String ^ GetDeviceSelectorFromShortId(unsigned short serviceShortId);
 static winrt::hstring GetDeviceSelectorFromShortId(uint16_t const& serviceShortId);
/// [Windows.Foundation.Metadata.Deprecated("Use GetDeviceSelectorFromUuid instead of GetDeviceSelectorFromShortId.  For more information, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 262144, "Windows.Foundation.UniversalApiContract")]
 static winrt::hstring GetDeviceSelectorFromShortId(uint16_t const& serviceShortId);
public static string GetDeviceSelectorFromShortId(ushort serviceShortId);
[Windows.Foundation.Metadata.Deprecated("Use GetDeviceSelectorFromUuid instead of GetDeviceSelectorFromShortId.  For more information, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 262144, "Windows.Foundation.UniversalApiContract")]
public static string GetDeviceSelectorFromShortId(ushort serviceShortId);
function getDeviceSelectorFromShortId(serviceShortId)
Public Shared Function GetDeviceSelectorFromShortId (serviceShortId As UShort) As String

Parameters

serviceShortId
UInt16

unsigned short

uint16_t

A 16-bit Bluetooth GATT Service UUID.

Returns

String

Platform::String

winrt::hstring

A suitable AQS Selector String which can be passed as a parameter to the CreateWatcher method, in order to retrieve a GATT service instance path

Attributes

Windows requirements

App capabilities
bluetooth

Applies to