Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
2009
Javascript error "Expected ')'" when setting chart's content to control's innerHTML
posted

Hi,

 I have an asp placeholder in a page and another UserControl containing UltraChart. Next I call Server.Execute to get the chart's html which I set to my placeholder's innerHTML. While setting the innerHTML, I am getting javascript error. The javascript error is "Expected ')'". This error is repeated for each onmouseXXX code that is generated by the chart. One such line is:

<area onmouseout="if(typeof(fdf6ec3a-d4cb-429c-a7d5-702ea3cce4e4_Chart1_pRcEv)!='undefined')fdf6ec3a-d4cb-429c-a7d5-702ea3cce4e4_Chart1_pRcEv(event, this,1,3,'MOUSE_OUT','17');" onclick="if(typeof(fdf6ec3a-d4cb-429c-a7d5-702ea3cce4e4_Chart1_pRcEv)!='undefined')fdf6ec3a-d4cb-429c-a7d5-702ea3cce4e4_Chart1_pRcEv(event, this,1,3,'MOUSE_CLICKED','17');" onmouseover="if(typeof(fdf6ec3a-d4cb-429c-a7d5-702ea3cce4e4_Chart1_pRcEv)!='undefined')fdf6ec3a-d4cb-429c-a7d5-702ea3cce4e4_Chart1_pRcEv(event, this,1,3,'MOUSE_OVER','17');" coords="241,81,371,92,372,93,240,82" shape="poly" />

When I remove these lines and then set the remaining innerHTML, there is no javascript error then.

This problem only occurs when I am setting chart's innerHTML. On another separate page where I have only one chart, there are no issues. Also in this case, ChartDataClicked event is not getting fired and no tooltips are shown.

Please let me know what I am missing. If you want, I will try to create a sample project for this.

Thanks.

Parents Reply Children
No Data