IChart.GetTotalBackground

Syntax

GetTotalBackground: IChartBackgroundInfo;

Description

The GetTotalBackground method returns fill color of chart total columns.

Example

Executing the example requires the the repository contains a form with the Button component named Button1, the Panel component named Panel1, and an express report with the EXPRESS_REPORT identifier.

Add links to the Chart, Express, and Metabase system assemblies.

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
    Chart: IChart;
    MB: IMetabase;
    Eax: IEaxAnalyzer;
    a, r, g, b: Integer;
Begin
    
//Connect to repository
    MB := MetabaseClass.Active;
    
//Get express report
    Eax := MB.ItemById("EXPRESS_REPORT").Edit As IEaxAnalyzer;
    
//Get chart
    Chart := Eax.Chart As IChart;
    
//Get fill of total columns
    a := Chart.GetTotalBackground.Color.A;
    r := Chart.GetTotalBackground.Color.R;
    g := Chart.GetTotalBackground.Color.G;
    b := Chart.GetTotalBackground.Color.B;
    Panel1.Color := 
New GxColor.CreateARGB(A, R, G, B);
End Sub Button1OnClick;

Clicking the button sets in the Panel component color for chart's totals columns in the specified express report.

See also:

IChart