i want to apply session on crystal report:
my session code on .aspx page:
string id;
Session.Add("Opr", "Edit");
id = GridView2.Rows[e.NewEditIndex].Cells[1].Text;
Session.Add("Case_Ref", id);
and my crystal report code:
protected void Page_Load(object sender, EventArgs e)
{
showreport();
}
private void showreport()
{
ReportDocument rd = new ReportDocument();
if (Session["rptType"].ToString() == "Item")
{
rd.Load(Server.MapPath("~/CrystalReport.rpt"));
CrystalReportViewer1.ReportSource = rd;
}
}
...
Go to the complete details ...