Exemplo n.º 1
0
        private void cmdDisplay_Click(object sender, EventArgs e)
        {
            //BusinessLayer.MISReport myIntakePerPlucker = new BusinessLayer.MISReport();
            BusinessLayer.MISReport myIntakePerPlucker = new BusinessLayer.MISReport();
            DataSet dataSetReport = new DataSet();

            dataSetReport.Tables.Add(myIntakePerPlucker.ViewIntakePerPlucker(dtFromDate.Value.Date, dtToDate.Value.Date));
            dataSetReport.WriteXml("IntakePerPlucker.xml");


            IntakePerPluckerRPT myIntakeperPluckerRpt = new IntakePerPluckerRPT();

            myIntakeperPluckerRpt.SetDataSource(dataSetReport);

            //BusinessLayer.GetEstateID myGetEstId = new BusinessLayer.GetEstateID();
            FTSPayRollBL.Division myGetEstId = new FTSPayRollBL.Division();
            myIntakeperPluckerRpt.SetParameterValue("companyName", myGetEstId.ListEstate().Columns[1].ToString());
            myIntakeperPluckerRpt.SetParameterValue("FromDate", dtFromDate.Value.Date);
            myIntakeperPluckerRpt.SetParameterValue("ToDate", dtToDate.Value.Date);

            ReportViewer myReportViewer = new ReportViewer();

            myReportViewer.crystalReportViewer1.ReportSource = myIntakeperPluckerRpt;
            myReportViewer.Show();
        }
        public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport()
        {
            IntakePerPluckerRPT rpt = new IntakePerPluckerRPT();

            rpt.Site = this.Site;
            return(rpt);
        }