活动点击高滑道派

时间:2013-01-02 22:33:10

标签: .net highcharts highlight highstock

我正在使用这个代码作为高品牌,但我想用它作为馅饼,我能做到吗?原因不起作用:/

url = ...
$.get(url, function (data) {
          hs.htmlExpand(null, {
          pageOrigin: {
          x: pageX,
          y: pageY
     },
     headingText: title,
     maincontentText: data
     });
});

我尝试直接在点击功能中添加该代码,并使用:

.AddJavascripFunction("test", 
                "hs.htmlExpand(null, {" +
                    "pageOrigin: {"+
                    "},"+
                    "headingText: '...: '," +
                    "maincontentText: 'msje'"+
                "});"
        ) 

但刷新页面(我不知道为什么)并且不要给我看窗口。有什么想法吗?

1 个答案:

答案 0 :(得分:1)

应该有用,看看例子:

http://jsfiddle.net/tkEwD/2/

chart = new Highcharts.Chart({
        chart: {
            renderTo: 'container'
        },
        title: {
            text: 'Browser market shares at a specific website, 2010'
        },
        series: [{
            type: 'pie',
            name: 'Browser share',
            data: [
                ['Firefox',   45.0],
                ['IE',       26.8],
                {
                    name: 'Chrome',
                    y: 12.8,
                    sliced: true,
                    selected: true
                },
                ['Safari',    8.5],
                ['Opera',     6.2],
                ['Others',   0.7]
            ]
        }]
    });