Esempio n. 1
0
        protected void btnCapNhat_Click(object sender, EventArgs e)
        {
            LoaiSanPhamDTO dto = new LoaiSanPhamDTO()
            {
                MaLoaiSP  = txtMaLoaiSP.Text,
                TenLoaiSP = txtTenLoaiSP.Text,
                TrangThai = ckTrangThai.Checked
            };

            if (LoaiSanPhamBUS.CapNhatLoaiSP(dto) > 0)
            {
                lbTrangThai.Text = "Cập nhật thành công";
                LoadDS();
            }
            else
            {
                lbTrangThai.Text = "Cập nhật thất bại";
            }
        }