Ejemplo n.º 1
0
        private void bt_moi_Click(object sender, EventArgs e)
        {
            resettext();
            Enable(true);
            cb_loaiNV.Refresh();
            cb_loaiNV.SelectedIndex = 2;
            tbl_NhanVien.ClearSelection();
            NhanVienBus nvBus = new NhanVienBus();

            txt_manv.Text      = (nvBus.MaNVNow() + 1).ToString();
            txt_manv.Enabled   = false;
            txt_ngayLam.Value  = DateTime.Now;
            txt_ngaysinh.Value = DateTime.Parse("12/31/1996");
            cb_loaiNV.Focus();
            bt_them.Visible   = true;
            bt_Luu.Visible    = false;
            txt_pass.ReadOnly = true;
            txt_user.ReadOnly = false;
            visiable_user(false);
            visiable_pass(false);
        }