0
votes

I'm trying to create an application where I can simulate a keyboard ,

  private void a_Click(object sender, EventArgs e)
    {
        SendKeys.Send("a");
    }

    private void b_Click(object sender, EventArgs e)
    {
        SendKeys.Send("b");
    }

    private void c_Click(object sender, EventArgs e)
    {
        SendKeys.Send("c");
    }

so like when the user press a button , the application will press the "actual" letter ,

Example: user press a_Click , press the button A on keyboard

now SendKeys Class does not support all the keyboard but only certain press , as shift , enter , space etc...

But what about the rest of the keyboard?

Thank you

1

1 Answers

0
votes

It is well described in MSDN site, Let me summarize few from the reference.

 - For Enter      --> SendKeys.Send("{ENTER}");
 - For UP ARROW   --> SendKeys.Send("{UP}");
 - For ESC        --> SendKeys.Send("{ESC}");
 - For TAB        --> SendKeys.Send("{TAB}");
 - For Keypad add --> SendKeys.Send("{ADD}");