From GT-MP
Jump to: navigation, search
Client-Side Function
System-users.png Client-Side Javascript.png JavaScript

Triggers every time a key on the keyboard is released.

This event is derrived from the .NET Control.OnKeyUp event.

The first argument in your handling method is object sender, and the second is KeyEventArgs e

The Keys enum can be found under System.Windows.Forms.Keys on MSDN. Keys not in this enum, you can figure out by printing the KeyValue property of the KeyEventArgs (e in the sample below). This will return an integer with the unique key that was pressed.


API.onKeyUp.connect(function callback);

Required Arguments

  • callback: parameter input should be in function type.

Usage example(s)

API.onKeyUp.connect(function (sender, e) {
  if (e.KeyCode === Keys.E) {
    // Do something.
    API.sendNotification('Lorem Ipsum.')