Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
KeyPress equivalent to identify actual character
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00393169
Message ID:
00393184
Views:
23
Hi Nigel.

>> Example: I need to prevent quote and double-quote from being entered. If I use the keypress event nKeyCode, this will not work with different keyboard mappings. Here, double-quote is shift+2 but I can't trap shift+2 because it will be different on other mappings. <<

The value ofnShiftAltCtrl is irrelevant here. nKeyCode gives you the ascii value of the key pressed. To disallow single and double quotes:
IF INLIST( nKeyCode, 34, 39 )
  NODEFAULT
ENDIF
Marcia
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform