string qry1 = "select top (1) a.coursename,a.name,a.feespaid,a.admissionid,b.invoicenumber from tb_studentfees a inner join tb_invoice b on a.admissionid=b.admissionid where a.admissionid="+ lbladmissionnumber.Text +" order by b.invoicenumber desc"; SqlCeDataAdapter da1 = new SqlCeDataAdapter(qry1, con); DataTable dt = new DataTable(); da1.Fill(dt); if (dt.Rows.Count > 0) { //opening crystal report ReportDocument reportdocument = new ReportDocument(); String path1 = HttpContext.Current.Request.PhysicalApplicationPath + "FessReceiptt.rpt"; reportdocument.Load(path1); //reportdocument.Load(Server.MapPath("~/FessReceiptt.rpt")); reportdocument.SetDataSource(dt); CrystalReportViewer1.ReportSource = reportdocument; CrystalReportViewer1.RefreshReport(); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)