DownLevel(El: Integer): Integer;
El — element index.
The DownLevel method returns index of calendar dictionary element which is positioned one level lower than the element index of which is passed by the El parameter. It returns -1 if there are no elements on the lower level.
Sub Main;
Var
MB: IMetabase;
Obj: IMetabaseObjectDescriptor;
CalClass: CalendarDimInstanceFactory;
Dim: IDimInstance;
CalInst: ICalendarDimInstance;
i: Integer;
Begin
Mb:=MetabaseClass.Active;
Obj:=Mb.ItemById("CALENDAR_DIM");
Dim:=Obj.Open(Null) As IDimInstance;
CalClass:=New CalendarDimInstanceFactory.Create;
CalInst:=CalClass.CreateCalendarDimInstance(Dim);
i:=CalInst.DownLevel(100);
End Sub Main;
After executing the example the "i" variable contains index of the child element of 100th dictionary element. Dictionary identifier: CALENDAR_DIM.
See also: