Ejemplo n.º 1
0
 private void grdFormaPago_CellValueChanged(object sender, DataGridViewCellEventArgs e)
 {
     try
     {
         if (EsGridFormaConstruido)
         {
             if (grdFormaPago.Rows[e.RowIndex].Cells["EsActivo"].Value != null && grdFormaPago.Rows[e.RowIndex].Cells["NumeroCopiasLiquidos"].Value != null && grdFormaPago.Rows[e.RowIndex].Cells["IdFormaPago"].Value != null)
             {
                 oHelper.ActualizarFormasPago(Int32.Parse(grdFormaPago.Rows[e.RowIndex].Cells["IdFormaPago"].Value.ToString()), Int32.Parse(grdFormaPago.Rows[e.RowIndex].Cells["NumeroCopiasLiquidos"].Value.ToString()), Int32.Parse(grdFormaPago.Rows[e.RowIndex].Cells["NumeroCopiasCanastilla"].Value.ToString()), Convert.ToBoolean(grdFormaPago.Rows[e.RowIndex].Cells["EsActivo"].Value.ToString()), grdFormaPago.Rows[e.RowIndex].Cells["Descripcion"].Value.ToString());
                 label37.Focus();
                 RecuperarFormaPago();
             }
         }
         else
         {
             if (grdFormaPago.ContainsFocus == false)
             {
                 RecuperarFormaPago();
             }
         }
     }
     catch (FormatException) {
     }
     catch (Exception ex)
     {
         RecuperarFormaPago();
         MessageBox.Show(ex.Message);
     }
 }