IKeyPreviewEventArgs

Description

The IKeyPreviewEventArgs interface contains properties of the argument of the OnKeyPreview event that occurs before the events related to key pressing.

Properties

  Property name Brief description
Cancel The Cancel property determines whether the next event related to the keys pressing occurs.
KeyMessage The KeyMessage property returns the value that indicates why the OnKeyPreview event was generated.

Properties inherited from IKeyEventArgs

  Property name Brief description
Key The Key property determines a code of the key that was pressed or released.
ShiftState The ShiftState property returns the value that corresponds to the state of auxiliary keys (SHIFT, ALT and CTRL) when the keyboard actions are executed.

See also:

Forms Assembly Interfaces