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

How to Read Editable Rows data from table control.

Former Member
0 Likes
1,031

Hi experts,

can any one solve my problem..Thanks in Advance.....

I have one requirement to read the information from the editable rows of Table control.

starting i am displaying my internal table values in Table control in disable mode.in my screen i have created one INSERT button.

when user clicks on that insert button one row should become editable.I have done this part.

Now my requirement is when user clicks on insert button first time one row will get editable and user enters the data in fields of table control..now again when user clicks on insert button i need to read the previous data from editable row of table control and i need to update this in my internal table .

So how can i check whether the Table control field is in editable mode or not???

Please reply me.

3 REPLIES 3
Read only

former_member209920
Active Participant
0 Likes
608

Hi Priya,

You can read newly inserted rows from EXTRACT structure in table control. And you can also read FLAG as 'N', 'U' or 'D'.

Regards,

ManuB

Read only

0 Likes
608

can you please explain in detail..because i am new to this module pool Programming

Read only

0 Likes
608

Hello Priya,

In table comtrol, we can find two structures, EXTRACT[] and TOTAL[] which contain the data shown in table control. When you insert some lines in table, EXTRACT is populated.

In TOTAL[], if a line is modified, it will contain a flag with value 'U',

            if line is deleted, it will contain a flag with value 'D',

          & if line is added or inserted, it will contain a flag with value 'N'.

Each row in TOTAL and EXTRACT is stored as string., So you need to cast it into your table structure as below.

FIELD SYBMOL: <FS_TOTAL> type your_table.

Data pi_table type your_table.

*** PI_TOTAL is your TOTAL or EXTRACT structure.

  LOOP AT pi_total ASSIGNING <fs_total> CASTING.

    APPEND <fs_total> TO pi_table.

  ENDLOOP.

  UNASSIGN: <fs_total>.

So after reading the value of PI_TABLE-FLAG you can preform your operations.

Hope this will help you,

Best Regards,

ManuB