コード例 #1
0
        private void GenerateReport(DateTime startDate, DateTime endDate, int?userId, int?printerId)
        {
            Tenant tenant = (Tenant)Session["tenant"];
            PrintedDocumentsReport report = new PrintedDocumentsReport(tenant.id, startDate, endDate, userId, printerId);

            report.InitializeComponents(reportSurface, new WebReportBuilder(), accountingMasterPage.dataAccess.GetConnection());
            report.SetPage(action, currentPage);
            report.BuildReport();
        }
コード例 #2
0
        private void button2_Click(object sender, EventArgs e)
        {
            DateTime startDate            = new DateTime(2011, 05, 01);
            DateTime endDate              = new DateTime(2011, 05, 31);
            FileInfo reportFile           = new FileInfo(@"C:\quickTest.pdf");
            PrintedDocumentsReport report = new PrintedDocumentsReport(1, startDate, endDate, null, null);

            report.InitializeComponents(reportFile, new PdfReportBuilder(), dataAccess.GetConnection());
            report.BuildReport();
        }