Keyup event

Rosebud

Registered User.
Local time
Today, 22:07
Joined
Dec 5, 2000
Messages
28
I'm trying to use the keyup event to detect that if CTL + Apostrophe were pressed at the same time, to tab the focus to the next control. But when I use the keyup event, the event runs and only one keycode is present, the one for APOSTROPHE. How do I get the keycode to read a combination of keys pressed?

Appreciate any help anyone can give me.
 
Try something like this:

Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
Dim boolCtrlDown As Boolean

boolCtrlDown = (Shift And acCtrlMask) > 0
If (boolCtrlDown = True) And (KeyCode = 17) Then
MsgBox "ctrl + ` pressed"
End If
End Sub

ntp
 

Users who are viewing this thread

Back
Top Bottom