Crystal reports - StringVar Array only showing last value
Hi Experts,
I am having some troubles to get an array working. I would like to have all row information displayed in 1 string. Currently i have report in which i made a grouping to show all countries.
Dataset:
GH1 China
GH1 Germany
GH1 Italy
I have made the following formulas
Initialize (placed in GH1)
Shared stringVar array countries := [""];
Shared numberVar x := 1;
Load (placed in GH1)
Shared numberVar x;
Shared stringVar array countries;
countries [x] := {ROW_COUNTRIES};
Redim preserve countries[UBound(countries)+1];
x := x+1;
Print (placed in Group Footer)
Shared stringVar array countries;
Join (countries, ", ")
Result (showing only the last value which is italy)
Italy,
Would someone be able to explain me what i am doing wrong ?
Thank you.
Kr-