示例#1
0
        private void imprimirPrestamobtn_Click(object sender, EventArgs e)
        {
            string prestamoID = clientehistoriaprestamolist.SelectedItems[0].SubItems[0].Text;

            if (prestamoID != "")
            {
                PrintDoc pd = new PrintDoc();
                pd.Prestamo(prestamoID);
                pd = null;
            }
        }
示例#2
0
        private void HacerPrestamo()
        {
            Cliente  cli   = new Cliente(codigotxt.Text);
            DateTime sDate = new DateTime(fechacal.SelectionRange.Start.Year, fechacal.SelectionRange.Start.Month, fechacal.SelectionRange.Start.Day);

            double cuotastr        = double.Parse(cuotatxt.Text);
            double capitalstr      = Double.Parse(capitaltxt.Text);
            double interesstr      = Double.Parse(interestxt.Text);
            string formadepagostr  = FormadePagocb.SelectedValue.ToString();
            string distribucionstr = distribucioncb.SelectedValue.ToString();
            int    pID;

            if (PrestamoID == "0")
            {
                pID = cli.Prestamo.Nuevo(sDate, capitalstr, interesstr, cuotastr, formadepagostr, distribucionstr);
            }
            else
            {
                pID = cli.Prestamo.Update(PrestamoID, sDate, capitalstr, interesstr, cuotastr, formadepagostr, distribucionstr, cviejo, iviejo);
            }

            // vaciar todo la field del formulario
            cuotatxt.Text    = "";
            capitaltxt.Text  = "";
            interestxt.Text  = "";
            pcuotasilb.Text  = "";
            codigotxt.Text   = "";
            nombretxt.Text   = "";
            pcapitalilb.Text = "";
            pinteresilb.Text = "";
            ptotalilb.Text   = "";
            //clear list cuota
            m_list.Items.Clear();
            m_list.Columns.Clear();

            if (MessageBox.Show("Quieres imprimir el Prestamo?", "Prestamo Grabado", MessageBoxButtons.YesNo) == DialogResult.Yes)
            {
                PrintDoc pd = new PrintDoc();
                pd.Prestamo(pID.ToString());
                pd = null;
            }
        }
示例#3
0
 private void imprimirPrestamobtn_Click(object sender, EventArgs e)
 {
     string prestamoID = clientehistoriaprestamolist.SelectedItems[0].SubItems[0].Text;
     if (prestamoID != "")
     {
         PrintDoc pd = new PrintDoc();
         pd.Prestamo(prestamoID);
         pd = null;
     }
 }