IDimensionViewer.DimGroup

Syntax

DimGroup: IDimElementGroup;

Description

The DimGroup property determines the dictionary elements group, based on which an element tree in the component is built.

Example

Executing the example requires a form with the Button1 button, the DimensionTree, DimensionCombo components and UiDimension that is a data source for DimensionTree and DimensionCombo. The dictionary loaded into UiDimension must have two groups of elements.

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);

Var

MB: IMetabase;

Groups: IMetabaseObjectDescriptors;

ElemGroup: IDimElementGroup;

Begin

MB := MetabaseClass.Active;

Groups := (UiDimension1.Dimension As IMetabaseObject).Children;

ElemGroup := Groups.Item(0).Bind As IDimElementGroup;

DimensionTree1.DimGroup := ElemGroup;

ElemGroup := Groups.Item(1).Bind As IDimElementGroup;

DimensionCombo1.DimGroup := ElemGroup;

End Sub Button1OnClick;

After executing the example, clicking the button displays the element tree based on the dictionary first group of elements in the DimensionTree1 component, the DimensionCombo1 component displays the element tree based on the dictionary second group of elements.

See also:

IDimensionViewer