|
|
|
start date: Wed, 08 Aug 2007 01:38:27 -0700,
posted on: microsoft.public.dotnet.framework.compactframework
back
| Thread Index |
|
1
oldsap
|
|
2
dbgrick
|
|
3
Fabien
|
|
4
oldsap
|
keydown, combination keys?
I have this code which works just fine for a single key press:
If e.KeyCode = 236 Then
MsgBox("alt") 'Alt key is pressed
End If
how do i code it when i want to capture the event wherein both "ALT'
key and a number/letter key are pressed simultaneously?
i tried this:
http://support.microsoft.com/kb/839201
but i can't seem to make it work on my smartphone wm6 device
Date:Wed, 08 Aug 2007 01:38:27 -0700
Author:
|
RE: keydown, combination keys?
The KeyUp or KeyDown event handler passes a KeyEventArts. This class
contains the key that was pressed and booleans indicating if the alt, control
or shift key is pressed. You can capture your number key and check the
additional arguments. See the following link:
http://msdn2.microsoft.com/en-us/library/system.windows.forms.keyeventargs.aspx
Rick D.
Contractor
"oldsap" wrote:
> I have this code which works just fine for a single key press:
>
> If e.KeyCode = 236 Then
> MsgBox("alt") 'Alt key is pressed
> End If
>
> how do i code it when i want to capture the event wherein both "ALT'
> key and a number/letter key are pressed simultaneously?
>
> i tried this:
> http://support.microsoft.com/kb/839201
> but i can't seem to make it work on my smartphone wm6 device
>
>
Date:Wed, 8 Aug 2007 06:34:05 -0700
Author:
|
Re: keydown, combination keys?
Hi,
Try to look at the function GetAsyncKeyState.
http://msdn2.microsoft.com/en-us/library/aa929803.aspx
Fabien Decret (Device Application Development MVP)
Windows Embedded Consultant
ADENEO (ADESET)
http://www.adeneo.adetelgroup.com/ | http://fabdecret.blogspot.com/
On 8 août, 10:38, oldsap wrote:
> I have this code which works just fine for a single key press:
>
> If e.KeyCode = 236 Then
> MsgBox("alt") 'Alt key is pressed
> End If
>
> how do i code it when i want to capture the event wherein both "ALT'
> key and a number/letter key are pressed simultaneously?
>
> i tried this:http://support.microsoft.com/kb/839201
> but i can't seem to make it work on my smartphone wm6 device
Date:Wed, 08 Aug 2007 06:46:43 -0700
Author:
|
Re: keydown, combination keys?
On Aug 8, 9:46 pm, Fabien wrote:
> Hi,
>
> Try to look at the function GetAsyncKeyState.http://msdn2.microsoft.com/en-us/library/aa929803.aspx
>
> Fabien Decret (Device Application Development MVP)
> Windows Embedded Consultant
>
> ADENEO (ADESET)http://www.adeneo.adetelgroup.com/|http://fabdecret.blogspot.com/
>
> On 8 août, 10:38, oldsap wrote:
>
> > I have this code which works just fine for a single key press:
>
> > If e.KeyCode = 236 Then
> > MsgBox("alt") 'Alt key is pressed
> > End If
>
> > how do i code it when i want to capture the event wherein both "ALT'
> > key and a number/letter key are pressed simultaneously?
>
> > i tried this:http://support.microsoft.com/kb/839201
> > but i can't seem to make it work on my smartphone wm6 device
Thank you for the replies.
GetAsyncKeyState function worked well.
Date:Thu, 09 Aug 2007 16:35:51 -0700
Author:
|
|
|