Settings: IPivotDimensionSettingsEx;
The Settings property returns data source dimension settings.
The settings store:
Dimension data filtering settings.
Settings for working with leaf elements.
Executing the example requires that the repository contains an express report with the EXPRESS identifier.
Add links to the Express, Metabase and Pivot system assemblies.
Sub UserProc;
Var
MB: IMetabase;
Express: IEaxAnalyzer;
Pivot: IPivot;
Dim: IPivotDimension;
Settings: IPivotDimensionSettingsEx;
Filter: IPivotDimensionFilterSettings;
Cond: IExpression;
Begin
// Get repository
MB := MetabaseClass.Active;
// Get express report
Express := MB.ItemById("EXPRESS").Edit As IEaxAnalyzer;
// Get display settings of report data table
Pivot := Express.Pivot;
// Get dimension from collection
Dim := Pivot.Dimensions.Item(0);
// Get dimension settings
Settings := Dim.Settings;
// Get dimension filtering settings
Filter := Settings.Filter;
// Get expression
Cond := Filter.Condition;
If Not Cond.Empty Then
Debug.WriteLine("Expression is not set") Else
Debug.WriteLine("Expression - " + Cond.AsString);
End If;
// Display only leaf dimension elements
If Not Settings.IsLeafElementsOnly Then
Settings.LeafElementsOnly := TriState.OnOption;
End If;
// Save changes
(Express As IMetabaseObject).Save;
End Sub UserProc;
After executing the example the table displays only the elements that do not have selected child elements.
See also: