Get the currently focused textbox in C#

Posted by chown on Stack Overflow See other posts from Stack Overflow or by chown
Published on 2010-05-30T03:51:41Z Indexed on 2010/05/30 3:52 UTC
Read the original article Hit count: 221

Filed under:
|

I have two textboxes, and a button. When I press the button, I want to know where my current caret is (either of the two boxes). I need this to know where to insert a certain text. I tried textbox1.Focused; textbox1.enabled but neither worked. How should I implement this? Thanks

© Stack Overflow or respective owner

Related posts about c#

Related posts about winforms