RemoveAt(Index: Integer);
Index. Index of position of the element that should be removed.
The RemoveAt method removes the element, which position index is passed by the input parameter.
Sub UserProc;
Var
ArrayL: IArrayList;
i: Integer;
Begin
ArrayL := New ArrayList.Create;
For i := 0 To Math.RandBetweenI(0, 100) Do
ArrayL.Add(Math.RandBetweenI(0, 50));
End For;
ArrayL.RemoveAt(ArrayL.Count - 1);
End Sub UserProc;
After executing the example a dynamic array with random values is created, and the last element is removed from it.
See also: