IMetaHierarchyAttributes.MoveAllTo

Syntax

MoveAllTo(Attributes: IMetaAttributesSet; LevelTo: IMetaHierarchyLevel; [IndexTo: Integer = -1);

Parameters

Attributes - attributes set that should be moved.

LevelTo - hierarchy level that the attributes set should be moved to.

IndexTo - hierarchy position index that the attributes set should be moved to. Optional parameter.

Description

The MoveAllTo method moves the attributes set to the specified level.

Example

Executing the example requires that the repository contains a time series database with the OBJ_FC identifier.

Sub Main;

Var

Mb: Imetabase;

Rubr: IRubricator;

Facts: IMetaDictionary;

Hierarchy: IMetaHierarchy;

HAttributes: IMetaHierarchyAttributes;

Begin

Mb := MetabaseClass.Active;

Rubr := MB.ItemById("OBJ_FC").Bind As IRubricator;

Facts := Rubr.Facts;

Hierarchy := Facts.DefaultHierarchy;

HAttributes := Hierarchy.Attributes;

HAttributes.MoveAllTo(HAttributes, Hierarchy.Levels.Item(0));

End Sub Main;

After executing the example all attributes are moved to the upper level of the hierarchy.

See also:

IMetaHierarchyAttributes