Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to detect if the shift key (only) is pressed
Message
De
05/08/2013 14:38:58
 
 
À
05/08/2013 14:30:57
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01579180
Message ID:
01579885
Vues:
60
The keypresses should not be being consumed. If they are I can provide you with code which only monitors the key flow, but does not consume.



>The control will now display Edit when I press the shift key. However, the one problem I ran into is that with this keystroke checking via BindEvents(), the navigation key presses are consumed if the the current control is a textbox. You won't be able to move the cursor with left/right/home/end. I tried two things to rectify this:
>1) In the bindevents trapping, issue a keypress for the "consumed" keystrokes. That only resulted in double keystrokes. argh. Hmmm, i am thinking that maybe the recursive flag may not have been turned off, that might make it work, but I don't have the time right now to verify that.
>2) In the KeyPress of the control, if the keystroke is a nav key, KEYBOARD the keypress with a NODEFAULT. This didn't work.
>
>At this time, I do not know how to make this solution work properly when a textbox has control. Otherwise, this is great.
>
>David
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform