IChartAxis.TextIsStagger

Fore Syntax

TextIsStagger: Boolean;

Fore.NET Syntax

TextIsStagger: System.Boolean;

Description

The TextIsStagger property determines whether the labels of the chart category axis can be arranged in a staggered pattern.

Comments

This property is relevant only for the category axis and any attempt to set this property for other types of axes throws an exception.

The labels can be arranged in a staggered pattern only if:

The property is saved together with the chart.

Fore Example

To execute this example, create a regular report with the Rep_1 identifier with a chart on the report sheet. The inspector of module assemblies should contain references to the following system assemblies: Chart, Report, Tab and Metabase.

Sub macro;
Var
    mb: IMetabase;
    report: IPrxReport;
    chart: IChart;
    aX: IChartAxis;
Begin
    mb := MetabaseClass.Active;
    report := mb.ItemById("Rep_1").Edit As IPrxReport;
    chart := (report.ActiveSheet As IPrxTable).TabSheet.Objects.Item(0).Extension As IChart;
    aX := chart.AxisX;
    aX.TextHorizontalAlignment := ChartHorizontalAlignment.Left;
    aX.TextIsStagger := True;
    aX.TextStaggerOddFirst := True;
    (report As IMetabaseObject).Save;
End Sub macro;

After executing the example, the category axis labels are arranged in a staggered pattern and aligned to the left with odd labels in the first row.

Fore.NET Example

To execute this example, create a regular report with the Rep_1 identifier with a chart on the report sheet. The inspector of module assemblies should contain links to the following system assemblies: Chart, Report, Tab.

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

...

Public Shared Sub Macro(Params: StartParams);
Var
    mb: IMetabase;
    report: IPrxReport;
    chart: IChart;
    aX: IChartAxis;
Begin
    mb := Params.Metabase;
    report := mb.ItemById["Rep_1"].Edit() As IPrxReport;
    chart := (report.ActiveSheet As IPrxTable).TabSheet.Objects.Item[0].Extension As IChart;
    aX := chart.AxisX;
    aX.TextHorizontalAlignment := ChartHorizontalAlignment.chaLeft;
    aX.TextIsStagger := True;
    aX.TextStaggerOddFirst := True;
    (report As IMetabaseObject).Save();
End Sub;

After executing the example, the category axis labels are arranged in a staggered pattern and aligned to the left with odd labels in the first row.

See also:

IChartAxis