In a Database I have a string witch obviously represents an array.
Tier||0,Tier|Insekte||1,Tier|Insekte|Biene||2,Pflanze||3,Pflanze|Blume||4,Pflanze|Blume|Zinnie||5
When I loop through the string to split the Words, I realize that the following characters disapear.
Here an example how I do that and gives the correct result.
ende := Length(str);
for i := ende downto 1 do begin
if str[i] = ',' then begin
out := out + '<' + copy(str,i+1,ende -i);
ende := i-1;
end;
if i = 1 then begin
out := out + '<' + copy(str,0,ende);
end;
end;
showmessage('out: ' + out);
So I think there is a hidden arrayfunction.
Before I go on I want to assure whats going on. Maybe I cold take further advantage going on with this project.
Is there a documentation of that availabe?
Postscriptum:
I just found that the removal must take place earliey by moving the value to my str....