private void toolStripStatus_ThemMoi_Click(object sender, EventArgs e)
 {
     try
     {
         if (!Common.Utilities.User.Administrator && !CheckQuyen(this.Name, 4))
         {
             return;
         }
         for (int j = 0; j < 100; j++)
         {
             if (BaoDong == "")
             {
                 frmXuLyKiemKeKho kk = new frmXuLyKiemKeKho("Insert", "Thêm mới phiếu kiểm kê kho");
                 kk.ShowDialog();
                 SelectData("");
             }
             else
             {
                 BaoDong = "";
                 break;
             }
         }
     }
     catch (Exception ex)
     { string s = ex.Message; }
 }
 private void dgvHienThi_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
 {
     try
     {
         if (dgvHienThi.RowCount > 0)
         {
             frmXuLyKiemKeKho kk = new frmXuLyKiemKeKho("Update", "Sửa phiếu kiểm kê kho", getDatagridview());
             kk.ShowDialog();
             SelectData("");
         }
     }
     catch (Exception ex)
     { string s = ex.Message; }
 }
 private void toolStripStatus_Sua_Click(object sender, EventArgs e)
 {
     try
     {
         if (!Common.Utilities.User.Administrator && !CheckQuyen(this.Name, 2))
         {
             return;
         }
         if (dgvHienThi.RowCount > 0)
         {
             frmXuLyKiemKeKho kk = new frmXuLyKiemKeKho("Update", "Sửa phiếu kiểm kê kho", getDatagridview());
             kk.ShowDialog();
             SelectData("");
         }
         else
         {
         }
     }
     catch (Exception ex)
     { string s = ex.Message; }
 }
 private void toolStripStatus_ThemMoi_Click(object sender, EventArgs e)
 {
     try
     {
         if (!Common.Utilities.User.Administrator && !CheckQuyen(this.Name, 4))
         { return; }
         for (int j = 0; j < 100; j++)
         {
             if (BaoDong == "")
             {
                 frmXuLyKiemKeKho kk = new frmXuLyKiemKeKho("Insert","Thêm mới phiếu kiểm kê kho");
                 kk.ShowDialog();
                 SelectData("");
             }
             else
             {
                 BaoDong = "";
                 break;
             }
         }
     }
     catch (Exception ex)
     { string s = ex.Message; }
 }
 private void toolStripStatus_Sua_Click(object sender, EventArgs e)
 {
     try
     {
         if (!Common.Utilities.User.Administrator && !CheckQuyen(this.Name, 2))
         { return; }
         if (dgvHienThi.RowCount > 0)
         {
             frmXuLyKiemKeKho kk = new frmXuLyKiemKeKho("Update","Sửa phiếu kiểm kê kho", getDatagridview());
             kk.ShowDialog();
             SelectData("");
         }
         else
         {  }
     }
     catch (Exception ex)
     { string s = ex.Message; }
 }
 private void dgvHienThi_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
 {
     try
     {
         if (dgvHienThi.RowCount > 0)
         {
             frmXuLyKiemKeKho kk = new frmXuLyKiemKeKho("Update", "Sửa phiếu kiểm kê kho", getDatagridview());
             kk.ShowDialog();
             SelectData("");
         }
     }
     catch (Exception ex)
     { string s = ex.Message; }
 }