ToArray: Array;
The ToArray method converts into regular string array.
If the current array is empty, the ToArray method returns Null.
Sub UserProc;
Var
StrL: IStringList;
s: Array Of String;
i: Integer;
Begin
StrL := New StringList.Create;
For i := 0 To Math.RandBetweenI(50, 100) Do
StrL.Add("Number " + Math.RandBetweenI(0, 100).ToString);
End For;
s := StrL.ToArray;
End Sub UserProc;
After executing the example the "s" variable contains a string array that consists of one string.
See also: