AutoRotateMarker: Boolean;
AutoRotateMarker: boolean;
The AutoRotateMarker property determines whether the chart contains the auto rotation of marker.
The AutoRotateMarker property use requires set the IChartMarker.MarkerType property to TriangleUp/TriangleDown/Rhombus or select marker type Triangular/Inverse triangular/Diamond on the chart:
Linear.
Scatter.
Radar.
Stepped.
Depending on the value change of the chart line series , the marker rotation angle changes dynamically.
Executing the example requires a regular report with the REGULAR_REPORT identifier where there are linear chart with two data series and markers as a triangle.
Add links to the Chart, Metabase, Report, Tab system assemblies in the module.
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(0) As IPrxTable).TabSheet;
Chart := Sheet.Objects.Item(0).Extension As IChart;
Chart.Series.DefaultSerie.ResetInheritance(ChartSeriePropertyInheritance.AutoRotateMarker);
// Set auto rotation of markers on the chart
Chart.AutoRotateMarker := True;
// Save regular report
(Report As IMetabaseObject).Save;
End Sub UserProc;
After executing the example auto rotation of markers in the graph direction is set on the regular report chart.
The requirements and result of the Fore.NET example execution match with those in the Fore example.
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[0] As IPrxTable).TabSheet;
Chart := Sheet.Objects.Item[0].Extension As IChart;
Chart.Series.DefaultSerie.ResetInheritance(ChartSeriePropertyInheritance.cspiAutoRotateMarker);
// Set auto rotation of markers on the chart
Chart.AutoRotateMarker := True;
// Save regular report
(Report As IMetabaseObject).Save();
End Sub;
See also: