Kannst folgende procedure verwenden.
Delphi-Quellcode:
procedure AssignStringArrayValues(var aStringArrayTarget: array of string;aStringArraySource: array of string);
var
lTargetIndex:Integer;
lSourceIndex:Integer;
begin
lTargetIndex:=Low(aStringArrayTarget);
lSourceIndex:=Low(aStringArraySource);
while (lTargetIndex<=high(aStringArrayTarget)) and
(lSourceIndex<=high(aStringArraySource)) do
begin
aStringArrayTarget[lTargetIndex]:=aStringArraySource[lSourceIndex];
Inc(lTargetIndex);
Inc(lSourceIndex);
end;
end;
Dann kannst du so die Daten zuweisen
Delphi-Quellcode:
var
myArray:array[3..5] of string;
begin
AssignStringArrayValues(myArray,['asdasd','asdasd']);
end;
Ungetestet.