score:10

Accepted answer

What exactly doesn't work for you? Are you using load event handler for this? See: http://jsfiddle.net/j3xvg/1/

chart = new Highcharts.Chart({
    chart: {
        renderTo: 'container',
        defaultSeriesType: 'line',
        marginRight: 50,
        marginBottom: 175,
        events: {
            load: function () {
                var chart = this;
                $(chart.series).each(function (i, serie) {
                    $('<li style="color: ' + serie.color + '">' + serie.name + '</li>').click(function () {
                        serie.visible ? serie.hide() : serie.show();
                    }).appendTo('#legend');
                });
            }
        }
    },
});

Related Query

More Query from same tag