winforms chart, change values on x axis
I have added values on x axis between 0-255. I add the values to a serie 开发者_C百科with serie.addXY(127,10000); When the chart is displayed, the values it shows on the x axis are -1, 49, 99...
How can I change this to display 0, 50,100?
Try setting axis bounds. You can do that in the designer or via code:
Chart1.ChartAreas["Default"].AxisX.Minimum = 0;
Chart1.ChartAreas["Default"].AxisX.Maximum = 255;
精彩评论