private void Add4_KeyDown(object sender, KeyEventArgs e) { if ((e.KeyCode == Keys.ShiftKey) | (e.KeyCode == Keys.Back && Add4.Text == "")) { Add3.Focus(); } }
private void Add2_TextChanged(object sender, EventArgs e) { if (Add2.Text.Length == 3) { Add3.Focus(); } }
private void Add2_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.ShiftKey | (e.KeyCode == Keys.Back && Add2.Text == "")) { Add1.Focus(); } else if (e.KeyCode == Keys.Decimal && Add2.Text.Length >= 1) { Add3.Focus(); } }
private void Add2_KeyPress(object sender, KeyPressEventArgs e) { if ((char.IsNumber(e.KeyChar) & RangeValidation(e.KeyChar.ToString(), Add2.Text)) | (char.IsControl(e.KeyChar) & (!char.IsWhiteSpace(e.KeyChar)))) { e.Handled = false; if (Add2.Text.Length >= 2) { Add3.Focus(); } } else { e.Handled = true; } }