Sign in to follow this  
francescoNemesi

IE8: getChartFromId returns object but calling methods on it does not work

Recommended Posts

Hi there,

 

 

 

My GWT application uses FusionCharts, I have a functionality to export server side to print the charts to PDF. All works fine in all browsers, but not in IE8. I start the export process with the following method:

 

 

 

public static native void exportChart(String divId) /*-{

 

var chart = $wnd.getChartFromId(divId);

 

if(chart.hasRendered()) chart.exportChart();

 

}-*/;

 

 

 

The var chart is returned as "Object" (i.e. not null), but after that, no matter which method I call on chart, I get the following error:

 

 

 

 

 

com.google.gwt.core.client.JavaScriptException: (TypeError): Object doesn't support this property or method

 

 

 

As I said, I have no problems with the other browsers. Can you please help me with urgency? I have a valid commercial license, this issue is stopping my application from going to production.

 

 

 

Thanks,

 

Francesco

Share this post


Link to post
Share on other sites
Guest Basundhara Ghosal

Hi,

Could you please send us the sample code that you are using for the same?

Awaiting your reply.

Share this post


Link to post
Share on other sites

Hi, I found the problem... I was assigning the same id to both the div container and embed tags. FF works anyway, but IE was trying to execute getChartFromId on the DIV element, hence failing.

 

 

 

Thanks for your help, Francesco

Share this post


Link to post
Share on other sites
Guest Basundhara Ghosal

Hi Fransesco,

Glad that your issue is resolved.

Happy FusionCharting. :D

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this