cancel
Showing results for 
Search instead for 
Did you mean: 

Table with varying number of columns

Former Member
0 Kudos

Hello experts,

my issue:

I need to print a table with varying number of columns. Depending on if all cells of a certain column are initial the

whole column should disappear. Hiding is not enough.

If this columns is in the middle of the table the following columns should move left to fill the gap.

my approach: (maybe there is an easier one)

There are 4 different possible situations. My approach was to create 4 different tables with different amount of

columns. In the interface I fill the table that is really needed from the source table data and fill a flag that characteristics

the situation, possible values (1,2,3,4).

In the form I'd like to print the appropriate table depending on the situations.

my problem:

How to place all 4 possible tables lying upon each other in the form and print only the needed one depending on the flag value?

my question:

Is my approach ok? Or is there an easier one?

If it is ok. How can I solve the problem regarding printing the right table.

Thanks in advance!

Heinz

Accepted Solutions (1)

Accepted Solutions (1)

vaibhav_tiwari
Contributor
0 Kudos

Hi Heinz,

You can handle it with FormCalc Script at initialization.

Suppose you have a table with name TABLE having a header HEADER and data row DATA:

TABLE-->HEADER(Cell1...Cell2...Cell3...Cell4)

--->DATA(Cell1...Cell2...Cell3...Cell4)

Suppose you want to hide Cell3 for null values, then write below code at initialization of DATA:

if(DATA[*].Cell3.rawValue eq null)
then
DATA[*].Cell3.presence = "hidden"
HEADER.Cell3.presence = "hidden"
else
DATA[*].Cell3.presence = "visible"
HEADER.Cell3.presence = "visible"
endif

Hope it would help.

Regards,

Vaibhav

Former Member
0 Kudos

Hello Vaibhav ,

thanks for Your support.

Unfortunately it does not hide.

Best regards

Heinz

Answers (0)