/// <summary> /// Leonardo Carrion /// 06/may/2021 /// Efecto: cargar el reporte con los datos filtrados /// Requiere: - /// Modifica: datasource del reporte /// Devuelve: - /// </summary> public void cargarDatosReporte() { Periodo periodo = new Periodo(); periodo.anoPeriodo = Convert.ToInt32(ddlPeriodos.SelectedValue); Proyectos proyecto = new Proyectos(); proyecto.idProyecto = Convert.ToInt32(ddlProyectos.SelectedValue); Unidad unidad = new Unidad(); unidad.idUnidad = Convert.ToInt32(ddlUnidades.SelectedValue); Session["listaReporteEgresos"] = reporte_DetalleEjecucionesServicios.getReporteEgresosPorUnidades(proyecto.idProyecto, periodo.anoPeriodo, unidad.idUnidad); ReportViewer1.Reset(); ReportViewer1.ProcessingMode = ProcessingMode.Local; ReportViewer1.LocalReport.ReportPath = Server.MapPath("ReporteDetalleEjecuciones.rdlc"); ReportDataSource reportDataSource = null; List <ReporteDetalleEjecucion> listaReporteDuracion = (List <ReporteDetalleEjecucion>)Session["listaReporteEgresos"]; reportDataSource = new ReportDataSource("DataSet1", listaReporteDuracion); if (reportDataSource.Equals(null) == false) { ReportViewer1.LocalReport.DataSources.Add(reportDataSource); } ReportViewer1.DataBind(); }
/// <summary> /// Leonardo Carrion /// 21/oct/2019 /// Efecto: cargar el reporte con los datos filtrados /// Requiere: - /// Modifica: datasource del reporte /// Devuelve: - /// </summary> public void cargarDatosReporte() { ReportViewer1.Reset(); ReportViewer1.ProcessingMode = ProcessingMode.Local; ReportViewer1.LocalReport.ReportPath = Server.MapPath("ReporteEgresosUnidades.rdlc"); ReportDataSource reportDataSource = null; List <Reporte_Egresos_Unidad> listaReporteDuracion = (List <Reporte_Egresos_Unidad>)Session["listaReporteEgresos"]; reportDataSource = new ReportDataSource("DataSet1", listaReporteDuracion); if (reportDataSource.Equals(null) == false) { ReportViewer1.LocalReport.DataSources.Add(reportDataSource); } ReportViewer1.DataBind(); }