Machsupport Forum
Mach Discussion => VB and the development of wizards => Topic started by: swarfboy on January 14, 2009, 05:24:15 PM
-
I have a homing and probing script that I wrote that is called from an external .m1s from a button in my screen set. The script runs fine but if the user hits the esc key during runtime the script doesn't exit. It stops current function and moves to the next function so you have to hit the esc key 3 times before it exits the script. How can I exit the script completely on the esc key event.
-
Put a "GetKey" function in your code, and so it will Exit on that key press
-
There is no such function. http://www.cypressinc.com/enduser.pdf
There should be a key press event built into mach because you can assign hotkeys.
I need to know how to assign these keys via a script so I can assign Esc = Exit Sub
I believe what Esc is currently canceling the While/Wend loop and jumping to the next While/Wend in my script.