HorizontalHotspotAlignment: ChartHorizontalAlignment;
The HorizontalHotspotAlignment property determines the horizontal position of a label.
The label position is set relative to the marker. By default the label is horizontally centered.
NOTE. When the Right/Left option is selected, the label is placed to the left or right. It is explained by the fact that starting point of label position is taken in the reverse order relative to the marker.
Executing this example requires a regular report a sheet of which contains a chart. A module is to be added to the report and the UserProc procedure is called from this module using the hyperlink. The inspector of module assemblies should contain links to the Chart, Report and Tab system assemblies.
Sub UserProc;
Var
Chart : IChart;
Serie : IChartSerie;
Begin
Chart := (PrxReport.ActiveReport.ActiveSheet As IPrxTable).TabSheet.Objects.Item(0).Extension As IChart;
Serie := Chart.Series.Item(0);
Serie.Label(2).Visible := True;
Serie.Label(2).HorizontalHotspotAlignment := ChartHorizontalAlignment.Right;
End Sub UserProc;
After executing the example, the third data label (label numeration starts with zero) is aligned to the left of the series.
See also: