My Assistant
|
|
Aug 5 2008, 10:09 AM
Post
#1
|
|
|
UtterAccess Veteran Posts: 430 From: 01902 ENGLAND |
Hi Everyone
Is there a way to tell if a user has held down, say the Ctrl key (I am assuming it will be pretty much the same whatever key I wish to trap for), when they have clicked on a control on a form..? Cheers Luke |
|
|
|
![]() |
Aug 5 2008, 10:43 AM
Post
#2
|
|
|
UtterAccess Addict Posts: 116 From: Michigan, USA |
On the 'Mouse Down' event there is a parameter called 'Shift' that contains the value of the key that was held down while the user mouse clicked.
Here's the text from the help page: Shift The state of the SHIFT, CTRL, and ALT keys when the button specified by the Button argument was pressed or released. If you need to test for the Shift argument, you can use one of the following intrinsic constants as bit masks: Constant Description acShiftMask The bit mask for the SHIFT key. acCtrlMask The bit mask for the CTRL key. acAltMask The bit mask for the ALT key. Alan |
|
|
|
Aug 5 2008, 10:59 AM
Post
#3
|
|
|
UtterAccess Veteran Posts: 430 From: 01902 ENGLAND |
Nice one Alan, that's just what I needed...
Cheers mate (IMG:http://www.utteraccess.com/forum/style_emoticons/default/thumbup.gif) |
|
|
|
![]() ![]() |
|
Go to Top · Lo-Fi Version | Time is now: 24th May 2013 - 08:39 PM |