Move(IndexFrom: Integer; IndexTo: Integer);
IndexFrom is index of the name that needs shifting.
IndexTo is index of the position into which the name should be shirted.
The Move method moves name in the collection.
Executing the example requires a form with the Button1 button on this form, the TabSheetBox component and the UiErAnalyzer component named UiErAnalyzer1 that is a data source.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
Eax: IEaxAnalyzer;
Pivot: IPivot;
PivotDim: IPivotDimension;
NamS: IPivotDimNamings;
Begin
Eax := UiErAnalyzer1.ErAnalyzer;
Pivot := Eax.Pivot;
PivotDim := Pivot.Dimensions.Item(0);
NamS := PivotDim.Namings;
NamS.Add;
Nams.Move(0, 1);
End Sub Button1OnClick;
After executing this example, two first elements of the names collection are switched.
See also: