I have a problem with my highchart my series is populated dynamically by looping my model. What if I also need to change the color of my highchart base on the value of my series.
Here is my code
series: [{
name: 'Flag',
showInLegend: false,
pointWidth:24,
pointPadding:0,
groupPadding:0,
data: (function()
{
var data = [];
@{
var itemSumaryListData = Model;
int subordinateCount = itemSumaryListData.subordinateCount;
if(itemSumaryListData.employeeteamlevelsummarylist.Count > 0){
foreach (var employee in itemSumaryListData.employeeteamlevelsummarylist) {
<text>data.push(@employee.TotalFlag );</text>
}
}
}
return data;
})()
}]
You can set color parameter:
http://jsfiddle.net/x8JVj/
You could try something similar to this JSFiddle and set the MaxValue from your chart data.
Then use this in series.zones: