crystalreportviewer always null

  • Thread starter Thread starter Jordan
  • Start date Start date
J

Jordan

Hi,

I've declared the statement below in my form and somehow
crystalReportViewer1 is always null. Is there anything wrong with the
statement?

private CrystalDecisions.Windows.Forms.CrystalReportViewer
crystalReportViewer1;

Thanks.

Regards,
Jordan
 
Hi,

Did you declared it in the aspx file?

Put this in the aspx file:

<CR:CrystalReportViewer id=CrystalReportViewer1
runat="server"></CR:CrystalReportViewer>

Note, check if you have this line at the beggining of the line, include it
if not
<%@ Register TagPrefix="cr" Namespace="CrystalDecisions.Web"
Assembly="CrystalDecisions.Web, Version=9.1.5000.0, Culture=neutral,
PublicKeyToken=692fbea5521e1304" %>

You can just double click the CrystalReportViewer component in the toolbox
and all the above will be included.

Cheers,
 
Back
Top