private void _SelectUpdateDoiTac()
 {
     try
     {
         int k = gridView1.SelectedRowsCount;
         if (k > 0)
         {
             int RowHandle = gridView1.GetSelectedRows()[k - 1];
             if (RowHandle >= 0)
             {
                 long      iDDT = long.Parse(gridView1.GetRowCellValue(RowHandle, colID).ToString());
                 Customers temp = Customers.Get(iDDT);
                 if (temp != null)
                 {
                     frmCustomers frm = new frmCustomers();
                     frm._cus = temp;
                     if (frm.ShowDialog() == DialogResult.OK)
                     {
                         _LoadDSDoiTac();
                     }
                 }
             }
         }
     }
     catch { }
 }
Example #2
0
        private void btnThemMoi_Click(object sender, EventArgs e)
        {

            frmCustomers frm = new frmCustomers();
            if (frm.ShowDialog() == DialogResult.OK)
            {
                _LoadDSDoiTac();
            }
        }
        private void btnThemMoi_Click(object sender, EventArgs e)
        {
            frmCustomers frm = new frmCustomers();

            if (frm.ShowDialog() == DialogResult.OK)
            {
                _LoadDSDoiTac();
            }
        }
Example #4
0
 private void _SelectUpdateDoiTac()
 {
     try
     {
         int k = gridView1.SelectedRowsCount;
         if (k > 0)
         {
             int RowHandle = gridView1.GetSelectedRows()[k - 1];
             if (RowHandle >= 0)
             {
                 long iDDT = long.Parse(gridView1.GetRowCellValue(RowHandle, colID).ToString());
                 Customers temp = Customers.Get(iDDT);
                 if (temp != null)
                 {
                     frmCustomers frm = new frmCustomers();
                     frm._cus = temp;
                     if (frm.ShowDialog() == DialogResult.OK)
                     {
                         _LoadDSDoiTac();
                     }
                 }
             }
         }
     }
     catch { }
 }