Пример #1
0
        private void txtBuscarCobroIngresar_ButtonClick(object sender, EventArgs e)
        {
            metCobros ObjMetCobros = new metCobros();

            ObjMetCobros.ExtraerDni(txtBuscarCobroIngresar);


            ObjMetCobros.InsertarDatosCobrosenformAgregar(txtBuscarCobroIngresar, txtNombreyApellido, txtDocumento, txtLegajo, cboCuotas, txtImporte, cboMediodepago);
            ObjMetCobros.ExtraerImporte(cboCuotas);
        }
Пример #2
0
        private void txtBuscarDatos_ButtonClick(object sender, EventArgs e)
        {
            metCobros ObjMetCobros = new metCobros();

            //if txtBuscarCobro is null no entra
            ObjMetCobros.ExtraerDni(txtBuscarDatos);

            ObjMetCobros.InsetarDatosCobrosenformBuscar(txtBuscarDatos, txtNombreyApellido, txtDocumento, txtLegajo, cboCuotas, txtImporte, cboMediodepago);
            ObjMetCobros.ExtraerImporte(cboCuotas);
            btnEditar.Visible = true;
        }
Пример #3
0
        private void cboCuotas_SelectionChangeCommitted_1(object sender, EventArgs e)
        {
            if (panlBtnAnular.Visible == false)
            {
                if (cboCuotas.SelectedIndex == 0)
                {
                    metCobros ObjMetCobros = new metCobros();
                    ObjMetCobros.ExtraerImporte(cboCuotas);

                    string importecuotaextraida = ObjMetCobros.ExtraerImporte(cboCuotas);

                    txtImporte.Text             = importecuotaextraida;
                    dtCobro.Value               = DateTime.Today;
                    cboMediodepago.SelectedItem = cboMediodepago.SelectedIndex = 0;
                    dtCobro.Enabled             = false;
                    txtImporte.Enabled          = false;
                    cboMediodepago.Enabled      = false;
                }

                else
                {
                    MessageBox.Show("Debe seleccionar la cuota pendiente con mayor fecha de vencmiento");
                }
            }
            else
            {
                metCobros ObjMetCobros = new metCobros();
                ObjMetCobros.ExtraerImporte(cboCuotas);

                string importecuotaextraida = ObjMetCobros.ExtraerImporte(cboCuotas);

                txtImporte.Text             = importecuotaextraida;
                dtCobro.Value               = DateTime.Today;
                cboMediodepago.SelectedItem = cboMediodepago.SelectedIndex = 0;
                dtCobro.Enabled             = false;
                txtImporte.Enabled          = false;
                cboMediodepago.Enabled      = false;
            }
        }
Пример #4
0
        private void btnEditar_Click(object sender, EventArgs e)
        {
            int idCobro = Convert.ToInt32(cboCuotas.SelectedValue.ToString());

            metCobros ObjMetCobros = new metCobros();
            string    resultado    = ObjMetCobros.AnularCobro(idCobro);

            if (resultado == "OK")
            {
                MessageBox.Show("La Cuota ha sido anulada con éxito.", "Cuota anulada", MessageBoxButtons.OK, MessageBoxIcon.Information);

                ObjMetCobros.ExtraerDni(txtBuscarDatos);

                ObjMetCobros.InsetarDatosCobrosenformBuscar(txtBuscarDatos, txtNombreyApellido, txtDocumento, txtLegajo, cboCuotas, txtImporte, cboMediodepago);
                ObjMetCobros.ExtraerImporte(cboCuotas);
            }
        }