Ejemplo n.º 1
0
        public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport()
        {
            HostReport rpt = new HostReport();

            rpt.Site = this.Site;
            return(rpt);
        }
Ejemplo n.º 2
0
        public static ReportDocument MakeHostRep(DateTime dtStart, DateTime dtEnd)
        {
            HostReport             rep = new HostReport();
            HostReportTableAdapter ta  = new HostReportTableAdapter();

            (rep.ReportDefinition.ReportObjects["Interval"] as TextObject).Text +=
                string.Format("{0} - {1}", dtStart, dtEnd);
            rep.SetDataSource((DataTable)ta.GetData(dtStart, dtEnd));
            HostUserReportTableAdapter uta = new HostUserReportTableAdapter();

            (rep.Subreports[0].ReportDefinition.ReportObjects["Interval"] as TextObject).Text +=
                string.Format("{0} - {1}", dtStart, dtEnd);
            rep.Subreports[0].SetDataSource((DataTable)uta.GetData(dtStart, dtEnd));
            return(rep);
        }