Wednesday 28 August 2013

How to capture Key press event for a text box?

How to capture Key press event for a text box?

I have a winform application which has two text boxes and a button. If the
control focus is on any of the text boxes and user clicks keyboard "enter"
button. The button event should invoke.
The issue is I couldn't find the TextBox_KeyDown to capture the "Enter"
key press. In the Visual Studio editor, KeyDown,KeyPress,Keyup properties
are empty.
Thanks in advanced for your help.

No comments:

Post a Comment