IPivotTableHeader.IsDimensionMergeAllowed

Syntax

IsDimensionMergeAllowed(DimKey: Integer): Boolean;

IsDimensionMergeAllowed(DimKey: uinteger): boolean;

Parameters

DimKey. Dimension key.

Description

The IsDimensionMergeAllowed property returns whether the dimension contained in table header can be tucked.

Comments

Available values:

Example

To execute the example, make sure that the repository contains an express report with the EXPRESS identifier. The express report contains two dimensions located in rows and joined into one slot.

Add links to the Express, Dimensions, Metabase, Pivot system assemblies.

Sub Main;
Var
    MB: IMetabase;
    Report: IEaxAnalyzer;
    Pivot: IPivot;
    info: String;
    TableHeader: IPivotTableHeader;
    dimKey: Integer;
Begin
    
// Get the current repository
    MB := MetabaseClass.Active;
    
// Get express report
    Report := MB.ItemById("EXPRESS").Bind As IEaxAnalyzer;
    
// Get object, based on which data table is built
    Pivot := Report.Pivot;
    
// Get table sidehead properties
    TableHeader := Pivot.ObtainTable.LeftHeader;
    
// Check if the first dimension is tucked
    dimKey := Pivot.LeftHeader.Dim(0).Key;
    info := Pivot.ObtainTable.LeftHeader.IsDimensionMergeAllowed(dimKey).ToString;
    Debug.WriteLine(info);
    
// Check if the second dimension is tucked
    dimKey := Pivot.LeftHeader.Dim(1).Key;
    info := Pivot.ObtainTable.LeftHeader.IsDimensionMergeAllowed(dimKey).ToString;
    Debug.WriteLine(info);
End Sub Main;

Imports Prognoz.Platform.Interop.Dimensions;
Imports Prognoz.Platform.Interop.Express;
Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.Pivot;

Public Shared Sub Main(Params: StartParams);
Var     
    MB: IMetabase;
    Report: IEaxAnalyzer;
    Pivot: IPivot;
    info: string;
    TableHeader: IPivotTableHeader;
    dimKey: uinteger; 
Begin     
    // Get the current repository
    MB := Params.Metabase;
    
// Get express report
    Report := MB.ItemById["EXPRESS"].Bind() As IEaxAnalyzer;
    
// Get object, based on which data table is built
    Pivot := Report.Pivot;
    
// Get table sidehead properties
    TableHeader := Pivot.ObtainTable().LeftHeader;
    
// Check if the first dimension is tucked
    dimKey := Pivot.LeftHeader.Dim[0].Key;
    info := Pivot.ObtainTable().LeftHeader.IsDimensionMergeAllowed[dimKey].ToString();
    System.Diagnostics.Debug.WriteLine(info);
    
// Check if the second dimension is tucked
    dimKey := Pivot.LeftHeader.Dim[1].Key;
    info := Pivot.ObtainTable().LeftHeader.IsDimensionMergeAllowed[dimKey].ToString();
    System.Diagnostics.Debug.WriteLine(info);
End Sub;

After executing the example the console window displays False for the first dimension because tucking is available for all dimensions but the first one, and True for the second dimension.

See also:

IPivotTableHeader