Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid control's MouseWheel event problem
Message
De
23/11/2003 16:29:04
Mike Sue-Ping
Cambridge, Ontario, Canada
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00852801
Message ID:
00852810
Vues:
24
Sergey,

I put your code into a grid's MouseWheel event and replaced the commented line to
WAIT WINDOW "Shift is down"
The wait window never shows. What gives? Have you tried this?

Thanks for the suggestion.

Mike


>Mike,
>
>You can use Windows API function GetKeyState to determine status of Shift key.
DECLARE SHORT GetKeyState IN WIN32API INTEGER
>#define VK_SHIFT    0x10
>#define VK_CONTROL  0x11
>IF GetKeyState( VK_SHIFT ) < 0
>  * SHIFT key is down
>ENDIF
>
>
>>I'm trying to determine if the Shift key is pressed when the MouseWheel event is fired for a grid. I've put the following code into the event:
>>
>>
>>IF nShift = 1
>>   WAIT WINDOW NOWAIT TRANSFORM(nShift)
>>ENDIF
>>
>>
>>It never executes. If I remove the IF/ENDIF, the wait window displays "0" if no key is pressed (as expected), but, no wait window appears if I press the Shift key. It appears to me that the grid's MouseWheel event does not respect the nShift parameter.
>>
>>
>>Anyone know what I'm doing wrong?
>>
>>TIA,
>>
>>Mike
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform