IChartSerieBase.AutoRotateMarker

Syntax

AutoRotateMarker: Boolean;

AutoRotateMarker: Boolean;

Description

The AutoRotateMarker property determines whether a chart contains the auto rotation of marker for data series.

Comments

To use the AutoRotateMarker property, set the IChartMarker.MarkerType property to TriangleUp/TriangleDown/Rhombus or select the marker type Triangular/Inverse triangular/Diamond on the charts:

Depending on the value change of the chart line series, the marker rotation angle changes dynamically.

Example

Executing the example requires a regular report with the REGULAR_REPORT identifier containing linear chart with two data series and markers as a triangle.

Add links to the Chart, Metabase, Report, Tab system assemblies in the unit.

Sub UserProc;
Var
    Mb: IMetabase;
    Report: IPrxReport;
    Sheet: ITabSheet;
    Chart: IChart;
Begin
    // Get current repository and regular report
    Mb := MetabaseClass.Active;
    Report := MB.ItemById("REGULAR_REPORT").Edit As IPrxReport;
    // Get report chart
    Sheet := (Report.Sheets.Item(0As IPrxTable).TabSheet;
    // Set auto rotation of markers for data series
    Chart := Sheet.Objects.Item(0).Extension As IChart;
    Chart.Series.Item(0).AutoRotateMarker := True;
    Chart.Series.Item(1).AutoRotateMarker := True;
    // Save regular report
    (Report As IMetabaseObject).Save;
End Sub UserProc;

Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.Chart;
Imports Prognoz.Platform.Interop.Report;
Imports Prognoz.Platform.Interop.Tab;

Public Shared Sub Main(Params: StartParams);
Var
    Mb: IMetabase;
    Report: IPrxReport;
    Sheet: ITabSheet;
    Chart: IChart;
Begin
    // Get current repository and regular report
    Mb := Params.Metabase;
    Report := MB.ItemById["REGULAR_REPORT"].Edit() As IPrxReport;
    // Get report chart
    Sheet := (Report.Sheets.Item[0As IPrxTable).TabSheet;
    // Set auto rotation of markers for data series
    Chart := Sheet.Objects.Item[0].Extension As IChart;
    Chart.Series.Item[0].AutoRotateMarker := True;
    Chart.Series.Item[1].AutoRotateMarker := True;
    // Save regular report
    (Report As IMetabaseObject).Save();
End Sub;

After executing the example, the marker direction depends on series value on the regular report chart.

See also:

IChartSerieBase