private void button10_Click_2(object sender, EventArgs e) { string username, password; username = SDU.Text; password = SDP.Text; username = username.Trim(); password = password.Trim(); idD = checkerD(username, password); if (idD == -1) { MessageBox.Show("Wrong Username Or Password"); SDU.Clear(); SDP.Clear(); } else { Form3 f3 = new Form3(); this.Hide(); f3.ShowDialog(); this.Close(); } }