Sign in to follow this  
Rahul Kumar

getChartFromId not Working?

Recommended Posts

The following works fine up until the last line.

 

 

 

var theHostname = location.host;

 

var chart1 = new FusionCharts("http://" + theHostname + "/FusionCharts/FCF_Line.swf", "fusion_chart_id_1", "600", "300", "0", "1");

 

chart1.setDataXML(theXML);

 

chart1.render("my_chart");

 

 

 

var chartObj = getChartFromId("fusion_chart_id_1");

 

chartObj.setDataXML(theXML);

 

 

 

The line:

 

 

 

chartObj.setDataXML(theXML);

 

 

 

...gives me the error:

 

 

 

chartObj.setDataXML is not a function

 

 

 

How can I correct this? Thanks in advance to all for any info.

Share this post


Link to post
Share on other sites

Okay, that makes sense. Thanks for the info.

 

 

 

I notice that FusionCharts 3 has several pricing levels... User, Enterprise, Site, etc. Can you provide a link to the page that says what the differences are between each level? Thanks in advance.

Share this post


Link to post
Share on other sites

Hi,

 
Could you please tell us the chart's SWF name?
 
[if it starts with FCF_*.swf, then you are using FusionCharts Free, and FusionCharts Free do not support those features.] 

Share this post


Link to post
Share on other sites

I've got this problem too. I'm NOT using FusionCharts Free. The name of the SWF is StackedColumn2D. For me it says Object doesn't support this function or method on the second line of this segment:

 


var chartObj = infosoftglobal.FusionChartsUtil.getChartObject(this.getAttribute('id'));

chartObj.setDataXML(strDataXML);

 

 

 

Note that this code is not from my code, it's from the FusionCharts javascript class. It only happens in IE. Firefox/Chrome work fine. What do I do?

Share this post


Link to post
Share on other sites

Also in IE a message comes up that says Object doesn't support that property or method, and script debugger shows this code:

 


try { document.getElementById("total_costs_employee").SetReturnValue(__flash__toXML(FC_Rendered("total_costs_employee")) ); } catch (e) { document.getElementById("total_costs_employee").SetReturnValue(""); }

 

I didn't write that code. I don't know where it comes from, except that total_costs_emplyee is the name of the chart I'm trying to render. What would cause that error?

Share this post


Link to post
Share on other sites

I have the same problem, I'm using oem license.

 

 

 

What I have found is that if you put an 'alert()' between the getChartFromId() and the setDataURL() it works fine, but it does not solve my problem since the charts that I'm using are supposed to run without user interaction.

 

 

 

Also, it is happening in IE and Firefox as well.

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