G
Guest
Custom text box to go to next text box in tab list. When the user types in a
text box and the max length is meet, the focus goes to the next text box in
the tab list. Here is my code so far, but I don't know what to put in the
first parameter of SelectNextControl, noted with a question mark.
class ClassTextBox : System.Windows.Forms.TextBox
{
protected override void OnEnter(System.EventArgs e)
{
base.OnEnter(e);
SelectAll();
}
protected override void OnTextChanged(EventArgs e)
{
base.OnTextChanged(e);
this.SelectNextControl(?, true, true, true, true);
}
}
text box and the max length is meet, the focus goes to the next text box in
the tab list. Here is my code so far, but I don't know what to put in the
first parameter of SelectNextControl, noted with a question mark.
class ClassTextBox : System.Windows.Forms.TextBox
{
protected override void OnEnter(System.EventArgs e)
{
base.OnEnter(e);
SelectAll();
}
protected override void OnTextChanged(EventArgs e)
{
base.OnTextChanged(e);
this.SelectNextControl(?, true, true, true, true);
}
}