Is there a way to specify the length of the string for each label on the X-axis?

I have very long string category values that are rotated 90 deg (reading vertical) and the chart auto-sizing is making the chart area very small in comparison to the axis label area.

I've tried Enabling the auto-fit and setting the wrapped option like in this post: How to Fix the X Axis values length in Microsoft chart controls

But it ends up with the same result as I have with Disabling auto-fit.

Is there some way to use the LabelsFormat option for a text string rather than a number/datetime?

有帮助吗?

解决方案

Haven't found a way to format character strings using the LabelFormat property.

One option is to use an expression in the Label property of the category group to limit the number of characters displayed. The below example limits the label string to 5 characters:

Expression

=LEFT(Fields!CategoryGroupField.Value, 5)

Screenshot

enter image description here

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top