BluetoothLEDevice.GetDeviceSelectorFromDeviceName(String) Method

Definition

Creates an Advanced Query Syntax (AQS) filter string that contains a query for the Bluetooth LE device name. The AQS string is passed into the CreateWatcher method to return a collection of DeviceInformation objects containing the specified Bluetooth LE device name.

public:
 static Platform::String ^ GetDeviceSelectorFromDeviceName(Platform::String ^ deviceName);
 static winrt::hstring GetDeviceSelectorFromDeviceName(winrt::hstring const& deviceName);
public static string GetDeviceSelectorFromDeviceName(string deviceName);
function getDeviceSelectorFromDeviceName(deviceName)
Public Shared Function GetDeviceSelectorFromDeviceName (deviceName As String) As String

Parameters

deviceName
String

Platform::String

winrt::hstring

The Bluetooth LE device name used for constructing the AQS string.

Returns

String

Platform::String

winrt::hstring

An AQS string that is passed as a parameter to the CreateWatcher method.

Windows requirements

Device family
Windows 10 (introduced in 10.0.10586.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
API contract
Windows.Foundation.UniversalApiContract (introduced in v2.0)
App capabilities
bluetooth

Applies to