예제 #1
0
        private void btn_exit_Click(object sender, EventArgs e)
        {
            ((Form)this.TopLevelControl).Close();
            frm_trangchu f = (frm_trangchu)this.Parent.Parent;

            f.ff.Show();
        }
예제 #2
0
        private void frm_kho_insert_Shown(object sender, EventArgs e)
        {
            frm_trangchu f = (frm_trangchu)this.f.Parent.Parent;

            txt_mnv.Text = f.ff.nd.Manv;
            DateTime today = DateTime.Today;

            txt_date.Text           = today.ToString("MM/dd/yyyy");
            comboBox1.DataSource    = this.f.tb;
            comboBox1.DisplayMember = "Tên nhà cc";
            comboBox1.ValueMember   = "Mã nhà cc";
        }
예제 #3
0
        private void btn_luu_Click(object sender, EventArgs e)
        {
            MessageBox.Show("Đổi mật khẩu thành công");
            checkbox.Checked = false;
            // frm_trangchu parentForm = (this.Parent as frm_trangchu);
            frm_trangchu f = (frm_trangchu)this.Parent.Parent;
            //MessageBox.Show(f.nd.Ten);
            string pass = txtpassword.Text;

            nguoidung.changePass(f.nd.Tendangnhap, pass);
            txtpassword.Text = pass;
        }
예제 #4
0
        private void button1_Click(object sender, EventArgs e)
        {
            int kq = nv.dangNhap(txtid.Text, txtpassword.Text);

            if (kq == 0)
            {
                MessageBox.Show("Sai tên đăng nhập hoặc mật khẩu");
            }
            else
            {
                // thuoc f = new thuoc();

                //nd.quyen =
                frm_trangchu f = new frm_trangchu(this);
                nd         = data.getData(txtid.Text);
                nd.Matkhau = txtpassword.Text;
                this.Hide();
                f.ShowDialog();
            }
        }