Hello all,
I am trying to tabulate multi cases based on a specific column value in for loop.
categorizes = Column(dt, "Categorize");
columnValues = Associative Array(categorizes << Get Values) << Get Keys;
For(i = 1, i <= N Items(columnValues), i++,
currentItem = columnValues[i];
obLoopY = Outline Box("categorize" || Char(currentItem),
dt << Tabulate(
Page Column(:Categorize(Char(currentItem))),
Show Control Panel(0),
Add Table(
Column Table(
Grouping Columns(:Underlayer, :RefEntity),
Analysis Columns(:M3S_Y)
),
Row Table(Grouping Columns(:TargetEntity))
),
SendToReport(Dispatch({}, "", TextBox, {Set Base Font("Heading")}))
)
);
boxY << append(obLoopY);
);
Problem is, the currentItem contains the columnValues from Categorize column.
If I just specify the item value, let's say "a" as one of columnValues.
I added Page Column( :Categorize( "a" ) ) into Tabulate method, then it works.
But I needed to run all values from for loop, I tried to make it Page Column( :Categorize( currentItem ) ), but it did not work and just gave me the whole value at once instead of splitting by currentItem.
I tried Page Column( :Categorize( currentItem ) ), Page Column( :Categorize( char(currentItem) ) ), but neither of them worked. Probably there is a very easy solution but I could not find it.
Anyone can help?
Thanks in advance
Edit (jthi): Added jsl formatting