Пример #1
0
        private Document reporte()
        {
            string usuarioNombre;
            double prescripcion = 0;

            if (hayContext)
            {
                usuarioNombre = usuario.Name;
            }
            else
            {
                usuarioNombre = app.CurrentUser.Name;
            }
            if (planSeleccionado() is PlanSetup)
            {
                prescripcion = ((PlanSetup)planSeleccionado()).TotalPrescribedDose.Dose / 100;
            }
            else if (planSeleccionado() is PlanSum)
            {
                foreach (PlanSetup plan in ((PlanSum)planSeleccionado()).PlanSetups)
                {
                    prescripcion += plan.TotalPrescribedDose.Dose / 100;
                }
            }

            return(Reporte.crearReporte(paciente.LastName, paciente.FirstName, paciente.Id, equipo(), plantilla.nombre, plantilla.nota, usuarioNombre, Convert.ToString(infoPlan()), Convert.ToString(prescripcion), DGV_Análisis));
        }
Пример #2
0
 private void BT_VistaPrevia_Click(object sender, EventArgs e)
 {
     /*PrintDocument pd = new PrintDocument();
      * pd = Imprimir.cargarConfiguracion();
      * printPreviewDialog1.Document = pd;
      * pd.PrintPage += new PrintPageEventHandler(printDocument1_PrintPage_1);
      *
      * printPreviewDialog1.ShowDialog();*/
     Reporte.exportarAPdf("APELLIDO", "Nombre", "12-34567", "plan", plantilla.nombre, Reporte.crearReporte("APELLIDO", "Nombre", "12-34567", "equipo", plantilla.nombre, plantilla.nota, "pa", "", "", DGV_Análisis));
     MessageBox.Show("Se creó");
 }
Пример #3
0
 private Document reporte()
 {
     return(Reporte.crearReporte("Apellido", "Nombre", "12-34567", "equipo", plantilla.nombre, plantilla.nota, "pa", "", "", DGV_Análisis));
 }
Пример #4
0
 private Document reporte()
 {
     return(Reporte.crearReporte("", "", "", "", plantilla.nombre, plantilla.nota, "", "", "", DGV_Análisis));
 }