예제 #1
0
        private void btnThemNCC_Click(object sender, EventArgs e)
        {
            txtTenNCC.Clear();
            txtDiaChi.Clear();
            txtSDT.Clear();

            txtTenNCC.Enabled = true;
            cboMaLoai.Enabled = true;
            txtTenNCC.Enabled = true;
            txtDiaChi.Enabled = true;
            txtSDT.Enabled    = true;
            btnLuuNCC.Enabled = true;
            btnXoaNCC.Enabled = false;
            btnSuaNCC.Enabled = false;
            if (dgvNhaCC.RowCount <= 0)
            {
                txtMaNCC.Text = "NCC01";
            }
            else
            {
                txtMaNCC.Text = ncc_bll.getMaNhaCungCap();
            }
            add    = true;
            update = false;
        }