Jump to content
Developer Wiki and Function Reference Links ×

CreateLayout shortcut assignment


hisa

Recommended Posts

Is it possible to assign a shortcut key to a button?

 

for example,
The dialog created by CreateLayout has a Place and a Cancel button.
[Place]
Place the object without closing the dialog. Assign the P key as a shortcut.

 

I know how to prevent the dialog from closing when -1 is specified in the event handler.

Link to comment

You could create another button that has "place but don't close" functionality. It can have a keyboard shortcut assigned to it. 

 

If you did assign a keyboard shortcut to the OK / PLACE button, there is no way you could distinguish between the shortcut being pressed and the button being clicked. To have two functions in your dialog, you will need two buttons. 

 

Raymond

  • Like 1
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...