Navigation:  Reference > Events >

Key Down

Previous pageReturn to chapter overviewNext page

This event will be triggered when any key on keyboard is pressed down.  Please note that it is a global event (although its name has no "global" prefix).  You can define its handler in any element, but you may need to check the focus owner before actually do something.  The figure below shows how:

keydown_focus_check

If you need to know which key is pressed in the event handler, you could use the "CURRENT_KEY_CODE" system property.  The figure below shows how:

keydown_keycode_check

This event is available for page and all elements.