Page 1 of 1

ASP.NET Render error

Posted: Mon May 10, 2004 10:07 pm
by 8125097
I need to add webcharts dynamically to my page. (Later we are porting to Sharepoint, so everything needs to be added dynamically).

The Render event throws the following error:
[NullReferenceException: Object reference not set to an instance of an object.]
Steema.TeeChart.Web.WebChart.CreatePictureFile(HtmlTextWriter writer)
Steema.TeeChart.Web.WebChart.Render(HtmlTextWriter output)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.Control.Render(HtmlTextWriter writer)
System.Web.UI.WebControls.WebControl.RenderContents(HtmlTextWriter writer)
System.Web.UI.WebControls.TableCell.RenderContents(HtmlTextWriter writer)
System.Web.UI.WebControls.WebControl.Render(HtmlTextWriter writer)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.Control.Render(HtmlTextWriter writer)
System.Web.UI.WebControls.WebControl.RenderContents(HtmlTextWriter writer)
System.Web.UI.WebControls.WebControl.Render(HtmlTextWriter writer)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.WebControls.Table.RenderContents(HtmlTextWriter writer)
System.Web.UI.WebControls.WebControl.Render(HtmlTextWriter writer)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.Control.Render(HtmlTextWriter writer)
System.Web.UI.WebControls.WebControl.RenderContents(HtmlTextWriter writer)
System.Web.UI.WebControls.WebControl.Render(HtmlTextWriter writer)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlForm.RenderChildren(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlContainerControl.Render(HtmlTextWriter writer)
System.Web.UI.HtmlControls.HtmlForm.Render(HtmlTextWriter output)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Control.RenderChildren(HtmlTextWriter writer)
System.Web.UI.Control.Render(HtmlTextWriter writer)
System.Web.UI.Control.RenderControl(HtmlTextWriter writer)
System.Web.UI.Page.ProcessRequestMain()

Any suggestions? the asp.net userid has permissions on the _chart_temp, so that doesn't seem to be the problem.

FIXED

Posted: Tue May 11, 2004 3:28 pm
by 8125097
I solved it through "voodoo programming" - I changed one variable at a time until it worked.

It turns out, one has to manually populate the myGraph.ID property. I would suggest some enhancement to the error handler to explain what actually went wrong where.

Posted: Tue May 11, 2004 3:57 pm
by Pep
Hi Brian,

thanks for the advise.
It turns out, one has to manually populate the myGraph.ID property. I would suggest some enhancement to the error handler to explain what actually went wrong where.
Ok, I've added this comment on our wish list to see what can we do.

Posted: Wed May 12, 2004 9:11 pm
by 8125097
Jose,

It seems that this particular issue is unlikely to occur very often, but in general, the error messages should provide some guidance to developers.