I am trying to initalize a HighStock Chart. If I use this method:
var chart = new Highcharts.Chart('StockChart', dataObject);
I am getting an error that the rendering div cannot be found. If I use this method:
$('#container').highcharts('StockChart', dataObject);
The Chart is redered as expected. What I am doing wrong in the first method?
regards, Marko
Here is the fiddle: http://jsfiddle.net/mkeuschn/K4Cj6/
If you create the chart like the first method, you have to delete the first parameter 'StockChart'. Heres the api: Highstock api
So, this should be the code:
var chart = new Highcharts.StockChart(dataObject);
Working fiddle: jsfiddle
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With