private void button3_Click(object sender, EventArgs e) { this.Hide(); ChooseMode frm3 = new ChooseMode(); frm3.Show(); }
private void button1_Click_1(object sender, EventArgs e) { if (textBox1.Text == Register.SetValueForText2 && textBox2.Text == Register.SetValueForText3) { this.Hide(); ChooseMode frm1 = new ChooseMode(); frm1.Show(); } else if (textBox1.Text == Register.SetValueForText2 && textBox2.Text == ForgotPass.SetValueForText4) { this.Hide(); ChooseMode frm2 = new ChooseMode(); frm2.Show(); } else { MessageBox.Show("Wrong username or password"); } try { connect1(); comm = new OracleCommand(); comm.Connection = conn; //MessageBox.Show("conn"); //comm.CommandText = "execute login(username, password);"; //MessageBox.Show("conn"); //int value = (int)comm.ExecuteScalar(); comm.CommandType = CommandType.Text; comm.ExecuteNonQuery(); this.Hide(); ChooseMode frm = new ChooseMode(); frm.Show(); conn.Close(); } catch (Exception ew) { Console.Write("error" + ew); } }