I have a scatter chart that displays the label values over the data points, however, they overlap. Is there a way to angle them, say at a 45degree angle like the mock-up below? Thanks much.
You can try something like this:private void ultraChart1_ChartDrawItem(object sender, Infragistics.UltraChart.Shared.Events.ChartDrawItemEventArgs e){ Text text = e.Primitive as Text; if (text != null && text.Path == null) { text.labelStyle.RotationAngle = 45; text.labelStyle.Orientation = TextOrientation.Custom; }}
This will rotate the labels inside the chart's plotting are and leave the axis labels untouched.
I'm doing it in vb and I cannot get labelStyle to be recognized.
txt = e.Primitive
txt.labelstyle.rotationangle = 45
txt.labelstyle.orientation = TextOrientation.Custom
I may ot have converted it to vb correctly, but I got it to run as below, but everyting except my datapoint labels is angled.
(e.Primitive, Text)
Then
txt.labelStyle.RotationAngle = 45
txt.labelStyle.Orientation = TextOrientation.Custom
If
everything is correct with the exception of "If Not IsNothing(txt.Path)". That statement should be reversed. ChartText items have a null path, so you should change it to "If IsNothing(txt.Path)"
Woohoo. TYVM.