General information
Category:
Forms & Form designer
>The user can close the form with CTRL+F4 or clicking the upper right corner or object with "ThisForm.release()" code. How could I make that the "ESC" would have the same effect?
Do you have a command button that closes the form? A button with the "Cancel" property set to .T. will automatically fire when the Esc key is hit. Or you could use the KeyPress property and wait for KeyCode 27 (You'll want to set the KeyPreview property in this case). Or you could use ON KEY LABEL or ON ESCAPE, but those would be the older ways of things, not very clean either.
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only