Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Any way to determine mouse button states?
Message
From
15/12/2001 09:05:11
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
14/12/2001 15:00:47
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00594595
Message ID:
00594791
Views:
16
>Hi All,
>
>Is there an API call out there that will tell me if the left or right mouse button is down?
>
>I'm working with a Flexgrid in a VFP6 form and having a hard time trying to determine how I got into a cell, by user keypress or mouse click. The VFP LastKey() function is useless in the ActiveX control and MCOL() doesn't seem to work either.
>
>I know there's a GetKeyState call, but I'm really looking for something along the lines of a GetMouseState. Any ideas? (I'm fresh out.)
>
>TIA
>
>Erik

Erik,
Why not use FlexGrid mouse events and call VFP methods as necessary ? It has mousedown and keydown events.
You could use GetAsyncKeyState API call too (VK_LBUTTON, VK_RBUTTON and VK_MBUTTON are 'physical' left,right,middle mouse button virtual codes - 1,2 and 4 respectively).
PS: mdown(),mcol(),mrow() work too but it'd be harder to translate coordinates to activex cell.
I strongly suggest HFlex instead of Flex.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform