Binds a key combination to "click" a Button object. When the binding is used, all of the relevant mouse handlers on the button (save for OnEnter and OnLeave) fire just as if the button were activated by the mouse (including OnMouseDown and OnMouseUp as the key is pressed and released).

See also Keybind functions.


success = SetBindingClick("key", "buttonName" [, "mouseButton"])


  • key - A key or key combination (e.g. "CTRL-2") (string, binding)
  • buttonName - Name of a Button object on which the binding simulates a click (string)
  • mouseButton - Name of the mouse button with which the binding simulates a click (string)


  • success - 1 if the key binding was successful; otherwise nil (1nil)