public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() { POItemReport rpt = new POItemReport(); rpt.Site = this.Site; return rpt; }
private void showGradeTotalsBtn_Click(object sender, System.EventArgs e) { GenericCrystalViewer v = new GenericCrystalViewer(); v.Text = "Monthly Sales View"; POItemReport report = new POItemReport(); EMDataSet copyDataSet = (EMDataSet)m_emDataSet.Copy(); foreach (EMDataSet.POItemTblRow itemRow in copyDataSet.POItemTbl) { if (!itemRow.IsCancelDateNull()) { itemRow.Delete(); continue; } if (itemRow.POID != GetHeaderRow().POID) itemRow.Delete(); } copyDataSet.AcceptChanges(); report.SetDataSource(copyDataSet); v.viewer.ReportSource = report; v.Show(); }