Esempio n. 1
0
 private void BtThem_Click(object sender, EventArgs e)
 {
     BUSSach bussach = new BUSSach();
     if (txtTensach.Text == "" || txtTacGia.Text == "" || txtGia.Text == "")
     {
         MessageBox.Show("Nhập thiếu thông tin");
     }
     else
     {
         sach.Masach = bussach.MaSachTuDong();
         ganProperties();
         bool result = DALSach.AddSach(sach);
         if (result == true)
         {
             MessageBox.Show("Thêm thành công");
             load();
         }
         else
         {
             MessageBox.Show("Thêm thất bại");
         }
     }
 }