Phliplip

Problem with Internet Explorer

Recommended Posts

Hi FC,

 

 

 

I have a strange problem occurring in Internet Explorer 6/7, works in FireFox.

 

 

 

I get 2 identical errors on line 1 character 86, as with all debugging in IE this is pretty useless, so in Microsoft Script Debugger i can see that the following line fails.

 

 

 

try { fcChart.SetReturnValue(__flash__toXML(FC_Loaded("fcChart")) ); } catch (e) { fcChart.SetReturnValue(""); } 

 

 

 

If change fcChart in code below to fcChart2 the fcChart in the code above also changes.

 

 

 


      fcChartId = 'fcChart';

      activeFlashId = fcChartId;

      fcChart = new FusionCharts("http://www.onindo.com/include/flash/charts_v3/ScrollLine2D.swf?ChartNoDataText=Loading chart data, please wait!", fcChartId, "700", "300", "0", "1");

	   fcChart.setDataXML("");

	   fcChart.render("fcChartDiv");

	   Event.observe(window, 'load', function() {

        init_range_slider('rangeSliderDiv');

        Event.observe(fcChartId, 'mousedown', registerFlashChartClick);

      });

	   updateSearch(fcChartId, '<?php echo $generatorUrl; ?>'); // Gets XML from a generator through AJAX and sends to flash using SetDataXML

 

 

 

I'm also using FusionMaps. And prototype.js/scrip.aculo.us, but tried to remove them without any change.

Share this post


Link to post
Share on other sites

Hi,

 

 

 

I've found out that if the registerWithJS bit is set to 1 the errors occour, if i disable it (=0) they don't.. but then our websites JS integration with the Chart, for obvious reasons don't work, neither in FF or IE :hehe:

Share this post


Link to post
Share on other sites

I found the error;

 

 

 

fcChartId = 'fcChart';

 

activeFlashId = fcChartId;

 

fcChart = new FusionCharts("http://www.onindo.com/include/flash/charts_v3/ScrollLine2D.swf?ChartNoDataText=Loading chart data, please wait!", fcChartId, "700", "300", "0", "1");

 

fcChart.setDataXML("");

 

 

 

Highlighted entries may not be the same, or you can say that fcChartId may not have a value that equals the name of a javascript variable.

Share this post


Link to post
Share on other sites

This is my code:

  <div id="live_monitor_chart" align="center" >

  </div>

  <SCRIPT src="FusionGadgets/JSClass/FusionCharts.js"></SCRIPT>

  <script type="text/javascript"> 

  //Instantiate the Chart

  var chart = new FusionCharts("FusionGadgets/Charts/RealTimeLine.swf", "live_monitor_chart", "600", "350", "0", "1");

  chart.setDataURL(escape("live_monitor_chart.xml?currTime=" + getTimeForURL()));

  //Finally, render the chart.

  chart.render("live_monitor_chart");

But i still get the error...

 

Share this post


Link to post
Share on other sites

Thanks, this did help with the first JS error.

But now i'm getting an error 'Object doesnt support this propary or method' on the

feedData() function:

var chartJS = getChartFromId("live_monitor_chart");

  //We need to create a querstring format incremental update, containing

  //label in hh:mm:ss format

  //and a value (random).

  var currDate = new Date();

  var label= currDate.getHours() + ":" + currDate.getMinutes() + ":" + currDate.getSeconds();

  var value = 8830;

 

  //Build data string in format &label=...&value=...

  var strData = "&label=" + label + "&value=" + value;

  //Feed it to chart.

  chartJS.feedData(strData);

 

The chart is outside of FORM element, registerWithJS flag is on, the chart is rendered and running behind apache.

Any ideas ?

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