‎2007 Apr 23 8:14 AM
Hi all,
I have a scenario where initially I am loading the data from the table into the table control on the screen. I have a button for adding new records into the table control. Initially the table control in diabled for editing . My requirement is that when I press the "ADD" button a new row should be available for editing and after entering the data into that row I should save the data into the table...
Waiting for reply..
‎2007 Apr 23 8:18 AM
hi..
welcome to sdn..
check the demo program <b>demo_dynpro_tabcont_loop_at.</b> for your requirement.
regards,
veeresh
‎2007 Apr 23 8:17 AM
hi
for the button click wtite the code in pai
append intial line to internal table which displays data in table control
also in pbo of that screen write the following
describe table it_list lines z_tc_list-lines .
it_list is internal table
z_tc_list-lines is table control
reagrds
navjot
reward if helpfull
feel free to revert
Message was edited by:
navjot sharma
‎2007 Apr 23 8:18 AM
hi..
welcome to sdn..
check the demo program <b>demo_dynpro_tabcont_loop_at.</b> for your requirement.
regards,
veeresh
‎2007 Apr 23 8:18 AM
Hi
You would have to add an initial line to the internal table. It would appear as a row for editing, where you could add data and save.
Regards
Dinesh
‎2007 Apr 23 11:10 AM
Hi Dinesh,
I am trying that only but still I am not getting it ... Can u elaborate on your suggestion .. Thank You
‎2007 Apr 23 11:14 AM
hi premal
boss in pai write the following code
case sy-ucomm
when 'add'.
appent intial line to itab.
endcase.
this will add a blank line to ur internal table
after this the screen will again be called at table control will again be filled from ur internal table so a blank line will appear.
regards
navjot
‎2007 Apr 23 11:21 AM
this in line with my last post
after writing the aboce code also write this in the pbo
describe table it_list lines z_tc_list-lines .
it_list is internal table
z_tc_list-lines is table control
regards
navjot
‎2007 Apr 23 11:38 AM
Thank You all ...
My Problem is solved... Thanks for your gr8 help ...
‎2007 Apr 23 11:38 AM