Example #1
0
        private void button7_Click(object sender, EventArgs e)
        {
            TripDriver t = new TripDriver();

            t.Show();
            this.Hide();
        }
Example #2
0
        private void button2_Click(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 DRIVER_TABLE";
                OracleDataReader rd = cmd.ExecuteReader();
                while (rd.Read())
                {
                    if (rd[2].ToString() == textBox7.Text && rd[4].ToString() == textBox8.Text)
                    {
                        MessageBox.Show("Welcome Back *_*");
                        textBox7.Text = "";
                        textBox8.Text = "";
                        TripDriver dd = new TripDriver();
                        dd.Show();
                        this.Hide();
                        Form1 b = new Form1();
                        b.Hide();
                    }
                }
            }
        }