Hi Shweta,
Currently, you cannot control the distance from the point in the case of the horizontally aligned text. You can, however, achieve this result using a callout annotation - for example:
NChart chart = nChartControl1.Charts[0];
NLineSeries line = new NLineSeries();
line.Values.Add(10);
line.Values.Add(20);
line.Values.Add(30);
line.Data
LabelStyle.Visible = false;
chart.Series.Add(line);
NRectangularCallout callout = new NRectangularCallout();
callout.Text = "Some
Label";
callout.UseAutomaticSize = true;
callout.Anchor = new NDataPointAnchor(line, 1, System.Drawing.ContentAlignment.MiddleCenter, System.Drawing.StringAlignment.Center);
callout.
ArrowLength = new NLength(40);
callout.
ArrowBasePercent = 0;
chart.ChildPanels.Add(callout);
It creates a callout that is on the right side of the point. The problem with this approach is that you'll also need to measure the text correctly in order to dynamically produce meaningful value for the
arrow length property. Let us know if you meet any problems.
Best Regards,
Nevron Support Team