score:4

Accepted answer

could you please try following:

 string rangeselectorconfig =  " {\n" +
            "                buttons: [{\n" +
            "                    type: 'day',\n" +
            "                    count: 3,\n" +
            "                    text: '3dias'\n" +
            "                }, {\n" +
            "                    type: 'week',\n" +
            "                    count: 1,\n" +
            "                    text: '1w'\n" +
            "                }]" +
            "            }" ;
 jsonvalue config = jsonparser.parselenient(rangeselectorconfig);
 chart.setoption("/rangeselector", config);

chart class (with help of configurable) doesn't parse json objects for you, so buttons in your code were passed as string literals to native hightcharts js.


Related Query