Class KeyEventArgs
Provides data for the KeyUp and KeyDown routed events, as well as related attached and Preview events.
Inherited Members
System.EventArgs.Empty
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: System.Windows.Input
Assembly: OpenSilver.dll
Syntax
public sealed class KeyEventArgs : RoutedEventArgs
Properties
| Improve this Doc View SourceHandled
Gets or sets a value that marks the routed event as handled. A true value for Handled prevents most handlers along the event route from handling the same event again.
Declaration
public bool Handled { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Key
Gets the keyboard key associated with the event.
Declaration
public Key Key { get; }
Property Value
Type | Description |
---|---|
Key |
KeyModifiers
Gets a value that indicates which key modifiers were active at the time that the pointer event was initiated.
Declaration
public ModifierKeys KeyModifiers { get; }
Property Value
Type | Description |
---|---|
ModifierKeys |
PlatformKeyCode
Gets an integer value that represents the key that is pressed or released (depending on which event is raised). This value is browser-specific.
Declaration
public int PlatformKeyCode { get; }
Property Value
Type | Description |
---|---|
System.Int32 |