I have my graph configured to get data from a database and it’s all set up correctly with all the data displaying as it should. I have also configured 2 tabs which switch the graphs from line to bar for convienience which works fine. However, I now have a problem where the graphs are completely messed up on Chrome but work fine on Firefox and IE!
This is the code for the graph.
var chart = new CanvasJS.Chart(“chartContainer”,
{
animationEnabled: true,
axisX:{
gridColor: “Silver”,
tickColor: “silver”,
labelAngle: -50
},
toolTip:{
shared:true
},
axisY: {
gridColor: “Silver”,
tickColor: “silver”
},
legend:{
verticalAlign: “bottom”,
horizontalAlign: “center”,
fontFamily: “Expressway-Rg”
},
data: [
{
type: “line”,
showInLegend: true,
lineThickness: 2,
name: “Orders Week Ending ” + “@Html.Raw(Model.OrdersWeekEnding)”,
markerType: “square”,
color: “#cc0000”,
dataPoints:@Html.Raw(Model.WeekEndingJson)
},
{
type: “line”,
showInLegend: true,
name: “Orders Week Ending ” + “@Html.Raw(Model.ComparisonOrdersWeekEnding)”,
color: “#000000”,
lineThickness: 2,
dataPoints:@Html.Raw(@Model.ComparisonWeekEndingJson)
}
]
});
chart.render();
Thanks in advance to anyone that can help!