SAP Knowledge Base Article - Public

1204861 - Error: "Object reference not set to an instance of an object" or blank page when drilling into charts/groups with the CrystalReportViewer Web control with Bind in page_load or Bind on external events

Symptom

You may encounter a blank page when drilling into charts or groups with the CrystalReportViewer Web control with Bind in page_load and doing/not doing correct postback check or Bind based on external events. This happens with a saved data report with/without parameters or a non-saved data report without parameters. For a non-saved data report with parameters, after entering the parameter value an error message appears:
 
"Object reference not set to an instance of an object"  
 

Cause

The issue has been identified and tracked under ID ADAPT00897373. This occurs when you bind a CrystalDecisions.Web.CrystalReportSource object directly to the viewer in the Page_Load event with a post back check:
 
if (!IsPostBack)
 

Resolution

To avoid problems, do not perform a postback check when you set the report source:

protected void Page_Load(object sender, EventArgs e)
{
this.CrystalReportViewer1.ReportSource = CrystalReportSource1;
}

Keywords

CR2008 CR 2008 XIR3 XI R3 XI3.0 XI3 3 3.0 TITAN RN , 7883875 , KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , Bug Filed

Product

Crystal Reports 2008 V0