key code problem

  • Thread starter Thread starter Mike Shen
  • Start date Start date
M

Mike Shen

I just want to generate a key event through another key event,say, when i
press "A" , on the keyup event , I want to generate "B" press event. how to
do it?
I am newbie for C#. sorry for this simple question.
 
You'll have to P/Invoke to PostKeybdMessage(). I'm pretty sure that there's
been a suitable wrapper for this function posted before and you could also
use OpenNETCF's Smart Device Framework (www.opennetcf.org). Check via
GoogleGroups for past references:

http://groups.google.com/group/micr...tframework?hl=en&lr=lang_en&ie=UTF-8&oe=UTF-8

If you want to generate a non-alphanumeric character (not "B", but Enter,
for example), you'll have to P/Invoke keybd_event(), instead (also wrapped
in OpenNETCF).

Paul T.
 
Back
Top