In my KeyDown EventHandler I need to know what is the KeyCode for “,” and “.”.
I can’t find them thats why I ask. Thanks!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
A key and a character are not the same thing. The keyboard layout transforms between them, and that transform isn’t trivial. Probably you’re doing the wrong thing when using
KeyDown. If you want to know which character a user entered you should useKeyPress, which gives the the already translated character.For example
Keys.Decimalis a key on the numpad that corresponds to.on the US layout, and,on the German layout.Keys.OemcommaandOemPeriodare likely,and.belows the letters. But on other layouts that may be different.