M
Minerva Jones
I override OnKeyDown in my form, and my form has KeyPreview=true. I'm
trying to implement it such that if the user starts typing, focus
jumps to a specific textbox without them having to select it. So in
OnKeyDown, I can say tbInput.Focus(), but the problem is that the
first key is missed (the one that OnKeyDown was called for). I figure
I could have some convoluted logic to add the character to
tbInput.Text, but the KeyDown might shift or a cursor key or any other
key that I'd want the textbox to receive but can't just add onto
..Text. I just feel I want to pass the OnKeyDown event onto the
textbox, but I don't see a way to do this.
Any ideas? Thanks!
trying to implement it such that if the user starts typing, focus
jumps to a specific textbox without them having to select it. So in
OnKeyDown, I can say tbInput.Focus(), but the problem is that the
first key is missed (the one that OnKeyDown was called for). I figure
I could have some convoluted logic to add the character to
tbInput.Text, but the KeyDown might shift or a cursor key or any other
key that I'd want the textbox to receive but can't just add onto
..Text. I just feel I want to pass the OnKeyDown event onto the
textbox, but I don't see a way to do this.
Any ideas? Thanks!