Skip to content

Commit fd1ab3e

Browse files
committed
fixed highchart.ValueAtX(..) exception
1 parent 70e3383 commit fd1ab3e

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed

Controls/Highcharts/Highchart.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -729,7 +729,7 @@ private double ValueAtX(Series s, int x)
729729

730730
var xCoef = (float)(x - cachedPlotLeft) / cachedPlotWidth;
731731
var dataIndex = (int)(xCoef * sdataCount);
732-
if (dataIndex > sdataCount)
732+
if (dataIndex >= sdataCount || dataIndex < 0)
733733
return 0;
734734

735735
return s.data[dataIndex];

Controls/Highcharts/gradientFill.mat

0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)