asp.net mvc - Format BalloonText with amCharts.AmGraph jquery -


i trying format tag [[value]] in balloontext using amcharts , jquery. need show number tag [[value]] without decimals , thousand comma separator, example 64578 64,578. how can format balloontext?

thanks!.

 // creates graph , adds actual chart var creategraph = function (title, valuefield, color, unit) {     try {         var graph = new amcharts.amgraph();         graph.title = title;         graph.labeltext = "[[value]]";         graph.balloontext = title + " of [[value]] " + unit + " \nrepresents [[percents]]% of total [[category]]";         graph.valuefield = valuefield;         graph.type = "column";         graph.linealpha = 1;         graph.fillalphas = 0.6;         graph.linecolor = color;         chart.addgraph(graph);     } catch (err) { showmodalmessage("error in creategraph() method: " + err); } } 

you should set chart.numberformatter = {precision:0, decimalseparator:'.', thousandsseparator:','}


Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -