WinForms event for TextBox focus?

前端 未结 4 1073
醉梦人生
醉梦人生 2021-02-07 08:13

I want to add an even to the TextBox for when it has focus. I know I could do this with a simple textbox1.Focus and check the bool value... but I don\'

4条回答
  •  我寻月下人不归
    2021-02-07 08:56

    I up-voted Hans Passant's comment, but it really should be an answer. I'm working on a Telerik UI in a 3.5 .NET environment, and there is no GotFocus Event on a RadTextBoxControl. I had to use the Enter event.

    textBox1.Enter += textBox1_Enter;
    

提交回复
热议问题