Add: IRdsLevel;
The Add method adds a level to an MDM dictionary.
A level with the ITEM<ordinal number> name and identifier is added by default.
Executing the example requires that the repository contains an MDM table dictionary with the DICT identifier.
Add links to the Metabase, Rds system assemblies.
Sub UserProc;
Var
MB: IMetabase;
Dict: IRdsDictionary;
Levels: IRdsLevels;
Level: IRdsLevel;
Begin
// Get current repository
MB := MetabaseClass.Active;
// Get MDM dictionary
Dict := MB.ItemById("DICT").Edit As IRdsDictionary;
// Get MDM dictionary levels
Levels := Dict.Levels;
// Add a new level
Level := Levels.Add;
Level.Id := "NEWLEVEL";
Level.Name := "Additional level";
// Save dictionary
(Dict As IMetabaseObject).Save;
End Sub UserProc;
After executing the example a level named with the Additional Level name and with the NEWLEVEL identifier will be added to the MDM dictionary.
See also: