Sign In| Join
Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post May 11, 2012 03:40 AM by amolshelke
Member
28 Points
51 Posts
May 10, 2012 05:08 AM|LINK
getting error crystalreport doesn't existing in current context..
Contributor
3230 Points
668 Posts
May 10, 2012 05:44 AM|LINK
if your earlier code is running
you only have to put crystalReport.RecordSelectionFormula = "month({tablename.ColumnName}) = 5 " this line
after crystalReport.Load(Server.MapPath("CrystalReport.rpt"));
is your code running before
if not have installed crystal reports
if you ars using vs2010 then use this link to install it http://support.microsoft.com/kb/317789
May 10, 2012 06:02 AM|LINK
still giving same error made following changes..and i have 2008 vs.
protected void btnreport_Click1(object sender, EventArgs e) { ReportDocument reportdocument = new ReportDocument(); reportdocument.Load(Server.MapPath("CrystalReport.rpt")); CrystalReport.RecordSelectionFormula = "month({TicketTranc.TranscDate}) = 5 "; CrystalReportViewer1.ReportSource = reportdocument; }
pls tell where i am getting wrong..see i am taken monthname from db and bounded to dropdownlist when i select jan.then jan.report will be shown..and taken one button btnreport writed above code on button.
thnx.
May 11, 2012 03:40 AM|LINK
Solved myself..
amolshelke
Member
28 Points
51 Posts
Re: how tocreate monthwise crystal reports.
May 10, 2012 05:08 AM|LINK
getting error crystalreport doesn't existing in current context..
tusharrs
Contributor
3230 Points
668 Posts
Re: how tocreate monthwise crystal reports.
May 10, 2012 05:44 AM|LINK
if your earlier code is running
you only have to put crystalReport.RecordSelectionFormula = "month({tablename.ColumnName}) = 5 " this line
after crystalReport.Load(Server.MapPath("CrystalReport.rpt"));
is your code running before
if not have installed crystal reports
if you ars using vs2010 then use this link to install it http://support.microsoft.com/kb/317789
( Mark as Answer if it helps you out )
View my Blog
amolshelke
Member
28 Points
51 Posts
Re: how tocreate monthwise crystal reports.
May 10, 2012 06:02 AM|LINK
still giving same error made following changes..and i have 2008 vs.
protected void btnreport_Click1(object sender, EventArgs e) { ReportDocument reportdocument = new ReportDocument(); reportdocument.Load(Server.MapPath("CrystalReport.rpt")); CrystalReport.RecordSelectionFormula = "month({TicketTranc.TranscDate}) = 5 "; CrystalReportViewer1.ReportSource = reportdocument; }pls tell where i am getting wrong..see i am taken monthname from db and bounded to dropdownlist when i select jan.then jan.report will be shown..and taken one button btnreport writed above code on button.
thnx.
amolshelke
Member
28 Points
51 Posts
Re: how tocreate monthwise crystal reports.
May 11, 2012 03:40 AM|LINK
Solved myself..