Hi Slava,
Buddy has a func on windows called keyIsDown() and keyIsPressed() that hav used with virtual key codes to monitor keystrokes. The virtual key codes for the 'f' keys (from 1-16) range from 112-127.
Every time you press a key you see if one of the 'f' keys are down... I wonder though, if this would actually prevent system level calls from happening (like help, etc). I have also used the keyboardControl xtra from meliora that gives you even more control over which keys can be used, but it requires a little more finagling to get started up.
~Mathew
Slava Paperno wrote:
Hm... I must be missing something important here. How exactly do I do this with Buddy API? I want to allow input to editable fields and I want to stop the function keys from inputting junk... What Buddy API calls do you recommend? Thanks! S.
At 07:40 PM 7/1/04 -0400, you wrote:
I think buddyAPI could help with this if the keycode stuff isn't working out...
~Mathew
Slava Paperno wrote:
I'm trying to intercept and cancel function key presses by using statements like this in the handler that is assigned as the keyDownScript: if the keyCode = 11 then --the F 12 key stopEvent exit end if The values of keyCode for the function keys are between 96 and 101, and also 103, 109, and 11. The reason I want to intercept these keypresses is that they enter junk into the editable member that has the focus. My intercept works for all function keys except F1, F2, F4, and F12. The interesting part is that any of these keypresses is detected, but only the other function key presses can be stopped. The F1, F2, F4, and F12 seem to be impervious to stopEvent. What am I doing wrong? How do I stop these keys from entering junk into editable members? This is in Dir MX (9) and Windows XP. Thanks, Slava
[To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]
