Ejemplo n.º 1
0
        private void button3_Click(object sender, EventArgs e)
        {
            Admin_Main_Menu amm = new Admin_Main_Menu();

            amm.Show();
            this.Hide();
        }
Ejemplo n.º 2
0
        private void Login_btn_Click(object sender, EventArgs e)
        {
            try
            {
                sda = new SqlDataAdapter("select count(*) from LA_tbl where username='******' and upassword='******'", conn);
                DataTable dt = new DataTable();
                sda.Fill(dt);
                if (dt.Rows[0][0].ToString() == "1")
                {
                    Admin_Main_Menu amm = new Admin_Main_Menu();
                    amm.Show();
                    this.Hide();
                }

                else
                {
                    MessageBox.Show("Invalid UserName OR Password!");
                }
            }
            catch (SqlException ex)
            {
                throw ex;
            }
        }