private void button2_Click_1(object sender, EventArgs e) { conn = new OracleConnection(ordb); conn.Open(); OracleCommand cmd = new OracleCommand(); cmd.Connection = conn; if (textBox7.Text == "" || textBox8.Text == "") { MessageBox.Show("Please Enter Your Data "); } else { cmd.CommandText = "Select * from USER_TABLE"; OracleDataReader rd = cmd.ExecuteReader(); while (rd.Read()) { if (rd[2].ToString() == textBox7.Text && rd[3].ToString() == textBox8.Text) { MessageBox.Show("Welcome Back *_*"); textBox7.Text = ""; textBox8.Text = ""; TripUser tu = new TripUser(); tu.Show(); this.Hide(); Form1 b = new Form1(); b.Hide(); } } } }
private void button7_Click_1(object sender, EventArgs e) { TripUser go = new TripUser(); go.Show(); this.Hide(); }