Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Changing number of rows oin a table control dynamically

Former Member
0 Kudos

Hi all

Is there a way to change the no of rows dynamically.

I have a requirement that at run time , depending on a condition, I have to change the no of rows in the table control to 1 row.

Is this possible to do?If else How?

Thanks.

3 REPLIES 3

valter_oliveira
Active Contributor
0 Kudos

Use variable <table_control_name>-lines. Change it's value at it's screen PBO.

Regards.

Valter Oliveira.

Former Member
0 Kudos

Hi Valter,

How to modify the table control after setting the value of lines as 1?

Can you illustrate this with an example?

Thanks

0 Kudos

You can redefine table control attributes eachtime PBO is called, because those attributes are dynamic. So although you defined tc-lines as 1 in first PBO execution, you can redefine to 2 if some condition is achieved,

One idea could be to create a global var, called tc_lines which is initialized as 1. In your PBO you shoud use: <tc>-lines = tc_lines.

In PAI, when you obtain your condition, you shoud here add or subract one from this global variable.

Regards,

Valter Oliveira.