In the main report I created a formule as follows to create a shared array:
WhilePrintingRecords;
shared stringvar Array inv1Array;
inv1Array:={PAYABLETCP.IDINV};
local NumberVar howmany:= count({PAYABLETCP.IDINV});
if howmany > 0 then inv1Array[1] +
if howmany > 1 then ', ' + inv1Array[2] +
if howmany > 2 then ', ' + inv1Array[3] +
if howmany > 3 then ', ' + inv1Array[4] +
if howmany > 4 then ', ' + inv1Array[5];
inv1Array[1];
Last line of the text is meant for displaying the first value in array.
On running the report I get following error message:
"A subscript must be between 1 and the size of the array"
I tried to insert a statement as = "redim inv1Array[3]"
but the same error message appears. It seems "redim" is not accepted.
In the subreport I created a formula with following text to display the array:
whileprintingrecords;
shared Stringvar array inv1Array;
inv1Array[1];
The error still remains.
I am stuck up.
WhilePrintingRecords;
shared stringvar Array inv1Array;
inv1Array:={PAYABLETCP.IDINV};
local NumberVar howmany:= count({PAYABLETCP.IDINV});
if howmany > 0 then inv1Array[1] +
if howmany > 1 then ', ' + inv1Array[2] +
if howmany > 2 then ', ' + inv1Array[3] +
if howmany > 3 then ', ' + inv1Array[4] +
if howmany > 4 then ', ' + inv1Array[5];
inv1Array[1];
Last line of the text is meant for displaying the first value in array.
On running the report I get following error message:
"A subscript must be between 1 and the size of the array"
I tried to insert a statement as = "redim inv1Array[3]"
but the same error message appears. It seems "redim" is not accepted.
In the subreport I created a formula with following text to display the array:
whileprintingrecords;
shared Stringvar array inv1Array;
inv1Array[1];
The error still remains.
I am stuck up.