Application Development and Automation 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: 
Read only

problem in copy the table control row

Former Member
0 Likes
504

Hi

Experts.

can i copy the row of tablecontrol in z-modulepool program and past into the next row.

if possible give me some sample code and is it possible enable the mouse clicks?.

Thanks in Advance.

Spandana.

Yes, it's possible. You will need a field of the type C to use as MARKED field and activate the mark feature in the tablecontrol. After selecting the row and pressing a button (something like copy), you can loop at internal table that is behind the table control and select the row with marked = 'X' and append to the internal table refreshing table control after that.

To enable mouse click you will need to activate the F2 in the status (select event) and handle it in the user-command module. To get the row selected use the instruction :

get cursor line <linevar>.

Then you will have the exact record in the internal table by selecting the row with the index :

SEL_INDEX = <tab control>-top_line + <linevar> - 1.

2 REPLIES 2
Read only

PedroGuarita
Active Contributor
0 Likes
469

Yes, it's possible. You will need a field of the type C to use as MARKED field and activate the mark feature in the tablecontrol. After selecting the row and pressing a button (something like copy), you can loop at internal table that is behind the table control and select the row with marked = 'X' and append to the internal table refreshing table control after that.

To enable mouse click you will need to activate the F2 in the status (select event) and handle it in the user-command module. To get the row selected use the instruction :

get cursor line <linevar>.

Then you will have the exact record in the internal table by selecting the row with the index :

SEL_INDEX = <tab control>-top_line + <linevar> - 1.

Read only

venkat_o
Active Contributor
0 Likes
469

Hello, <li>Check the below thread. It looks same. <b> Thanks Venkat.O