KeyRoutedEventArgs.DeviceId Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets a unique ID for the input device that generated this key event (not supported for all input devices).
public:
property Platform::String ^ DeviceId { Platform::String ^ get(); };
winrt::hstring DeviceId();
public string DeviceId { get; }
var string = keyRoutedEventArgs.deviceId;
Public ReadOnly Property DeviceId As String
Property Value
A unique identifier for the input device associated with the key event, or an empty string for an unsupported device. The same device can be assigned a different ID each time it is connected.
Remarks
DeviceId can be used to differentiate between all connected devices that can generate key events.