IStandardDimIndexes.Add

Syntax

Add: IStandardDimIndex;

Description

The Add method adds an index to table dictionary.

Example

Sub Main;

Var

MB: IMetabase;

MObj: IMetabaseObject;

Dim: IStandardDimension;

DimInds: IStandardDimIndexes;

DimIndex: IStandardDimIndex;

Begin

MB:=MetabaseClass.Active;

MObj:=MB.ItemById("TAB_DIM").Edit;

Dim:=MObj As IStandardDimension;

DimInds:=Dim.Indexes;

DimIndex:=DimInds.Add;

DimIndex.Name:=ID index;

DimIndex.Id:="Index_Id";

DimIndex.Attributes.Add(Dim.Attributes.Id);

MObj.Save;

End Sub Main;

After executing the example table dictionary contains attribute index functioning as ID. Table dictionary identifier: TAB_DIM.

See also:

IStandardDimIndexes