Dela via


BluetoothDevice.FromIdAsync(String) Method

Definition

Returns a BluetoothDevice object identified by the given DeviceId.

public:
 static IAsyncOperation<BluetoothDevice ^> ^ FromIdAsync(Platform::String ^ deviceId);
/// [Windows.Foundation.Metadata.RemoteAsync]
 static IAsyncOperation<BluetoothDevice> FromIdAsync(winrt::hstring const& deviceId);
[Windows.Foundation.Metadata.RemoteAsync]
public static IAsyncOperation<BluetoothDevice> FromIdAsync(string deviceId);
function fromIdAsync(deviceId)
Public Shared Function FromIdAsync (deviceId As String) As IAsyncOperation(Of BluetoothDevice)

Parameters

deviceId
String

Platform::String

winrt::hstring

The DeviceId value that identifies the BluetoothDevice instance.

Returns

After the asynchronous operation completes, returns the BluetoothDevice object identified by the given DeviceId.

Attributes

Windows requirements

App capabilities
bluetooth

Remarks

This method must be called from a UI thread.

Applies to