Example #1
0
        private void btnAceptar_Click(object sender, EventArgs e)
        {
            try
            {
                pg.IdColono = idcolono;
                //pg.IdPago = idPago;

                dp.IdConcepto    = idcon;
                dp.IdDetallePago = idDetalle;
                dp.Idmes         = Convert.ToInt32(dtMes.ValueMember.Length);
                dp.Idtipo        = Convert.ToInt32(comboBox1.SelectedValue);
                dp.Cantidad      = cant;
                dp.CostoTotal    = Convert.ToDouble(this.dataGridView1.Rows[fila].Cells[4].Value);
                dp.CostoUnitario = Convert.ToDouble(this.dataGridView1.Rows[fila].Cells[3].Value);
                //pg.Total = total;
                dp.Total1 = total;
                pc.insertarPago(pg, dp);
                this.Close();
            }
            catch (Exception ex)
            {
                MessageBox.Show("Error: " + ex.Message + ex.StackTrace);
            }
        }