c# - labels in google column charts -
i'm using asp c# , followed tutorial create google charts http://www.dotnetfox.com/articles/create-google-column-chart-from-database-in-asp-net-1066.aspx
but need add labels each of bars in charts looks similar this: https://jsfiddle.net/5bd2lkyq/
i dont know how or add anotation:
var data = google.visualization.arraytodatatable([ ['city', '2010 population', {type: 'string', role: 'annotation'}, '2000 population', {type: 'string', role: 'annotation'}],
i got work
str.append("var view = new google.visualization.dataview(data);"); str.append(" view.setcolumns([0,1,{role: 'annotation',type: 'string',calc: 'stringify', sourcecolumn: 1}]);"); then change data view
str.append(" chart.draw(view, options);}");
Comments
Post a Comment