When you use the chart control in vs2012, there are too many labels on the X axis, so that only some of them can be displayed by default,
Of course, we can set to display all labels on the X axis.
First, find the "ChartAreas set" through the chart control properties, and click
So I came to the ChartAreas Set Editor, found the "Axes set" in the ChartAreas1 attribute on the right, and clicked it,
Because we want to set the x Axis, select "x axis" on the left of the Axis Set Editor.
Select "IntervalAutoMode" in the properties on the right and select "VariableCount" in the following items to set the x-axis interval to variable,
Variable X axis Interval
In this case, if there are too many labels on the X axis, the labels on the X axis may not be displayed. Therefore, the labels on the X axis must be displayed in the upper and lower layers.
Find the IsStaggered attribute in the Axis collection editor and set it to "True".
In the Axis collection Editor, find the IsStaggered attribute and set it to "True".
Then, all labels on the X axis are displayed.
Of course, there is another way to make the X axis label Rotate 90 degrees to display,
After changing the X Axis, select the Angle option in the "Axis Set Editor" and set the value to 90,
After changing the X Axis, select the Angle option in the "Axis Set Editor" and set the value to 90,
Click "OK" to exit the settings.
Run