private void LoginFormPassTextBox_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.Enter) { LoginFormLoginButton.PerformClick(); e.SuppressKeyPress = true; e.Handled = true; } }