public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() { HPDataRPT rpt = new HPDataRPT(); rpt.Site = this.Site; return(rpt); }
private void hpData_Click(object sender, EventArgs e) { DataSet dataSetReport = new DataSet(); dataSetReport = HoliPay.getHPData(2014, cmbDivision.SelectedValue.ToString()); dataSetReport.WriteXml("HPData.xml"); HPDataRPT myaclist = new HPDataRPT(); myaclist.SetDataSource(dataSetReport); ReportViewer myReportViewer = new ReportViewer(); myReportViewer.crystalReportViewer1.ReportSource = myaclist; myReportViewer.Show(); }