public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() { RYearRpt rpt = new RYearRpt(); rpt.Site = this.Site; return(rpt); }
private void GetReport() { if (Request.QueryString["Year"] != null) { RYearRpt objRpt = new RYearRpt(); crystalReport = objRpt; a.ExcecuteQuery("select Bill_no,Return_date,sum(0+P_sold) as price,Sum(0+P_tot) as total,Sum(0+P_tot)-sum(0+P_sold) as tax from SalesRTable where Year(Return_date)='" + Request.QueryString["Year"] + "' group by Bill_no,Return_date "); crystalReport.SetDataSource(a.DT); crystalReport.SetParameterValue("year", Request.QueryString["Year"].ToString()); CrystalReportViewer1.ReportSource = crystalReport; } }