2015 Jun 15 5:11 AM
Hi All,
I have created Table control in my module pool program. Initial data load to the Table control in working fine. when i m change the QTY field in Table control and scroll it , That changed data will refreshed.
i have checked in debug mode, when scroll the table control , it is directly go to the PAI.
Please help me to solve the problem
Thanks
pramod
2015 Jun 15 5:29 AM
Hello Pramod,
Although I've understood your problem partially are the entry quantities getting cleared then you need to write a logic in pai that is a module .
For example.
PAI.
loop
endloop.
module modify
MODIFY itab FROM WA INDEX TCL-currentline (table control).
if sy-subrc <> 0.
append wa to itab.
endif.
OR else if I am wrong kindly refer this programs which might help you these are standard programs.
demo_dynpro_tabcont_loop.
RSDEMO_TABLE_CONTROL.
Hope this is helpful.
Thanks and Regards,
Sandeep.
2015 Jun 15 5:29 AM
Hello Pramod,
Although I've understood your problem partially are the entry quantities getting cleared then you need to write a logic in pai that is a module .
For example.
PAI.
loop
endloop.
module modify
MODIFY itab FROM WA INDEX TCL-currentline (table control).
if sy-subrc <> 0.
append wa to itab.
endif.
OR else if I am wrong kindly refer this programs which might help you these are standard programs.
demo_dynpro_tabcont_loop.
RSDEMO_TABLE_CONTROL.
Hope this is helpful.
Thanks and Regards,
Sandeep.
2015 Jun 15 5:41 AM
Hi Sandeep,
This is my PAI Coding,
process after input.
module exit_9100.
loop at gt_out.
module modify_table_ctrl.
module user_command_9100.
endloop.
Thanks
pramod
2015 Jun 15 6:46 AM
Dear Sandeep,
I checked program ' demo_dynpro_tabcont_loop ' - when i m scrolling data not refreshed, but scroll more, time out will occur.
please advice .
program 'RSDEMO_TABLE_CONTROL' - not full fill my requirement, data will refreshed.
thanks
2015 Jun 15 5:30 AM
HI PRAMOD,
I hope after change in Qty field some event trigger, which cause some malfunction.
I am agree with u that scroll in table control it goes to PAI event.
check in QTY field that any ok is their or not and confirm u generate table control with wizard or create manually .
Share your code for analysis.
2015 Jun 15 5:39 AM
Hi Swadhin,
This is my PAI Coding,
process after input.
module exit_9100.
loop at gt_out.
module modify_table_ctrl.
module user_command_9100.
endloop.
Thanks
pramod
2015 Jun 15 5:52 AM
process after input.
module exit_9100.
loop at gt_out.
module modify_table_ctrl.
module user_command_9100. => remove from loop.
endloop.
use here
module user_command_9100.
and check
2015 Jun 15 6:11 AM
2015 Jun 15 6:47 AM
HI,
Please share total flow logic of screen i.e PBO and PAI with perform code.
I suggest mean while you try to create with help of Wizard .
2015 Jun 15 7:03 AM
Hi Swadin,
process before output.
loop at gt_out into gs_out with control tab_ctrl.
module table_ctrl.
endloop.
***************************************************
**-------------- PBO ( screen 9100 ) ------------**
***************************************************
* Loading data to Table controll
module table_ctrl output.
zst_item-sdat = gs_out-sdat.
zst_item-werks = gs_out-werks.
zst_item-stloc = gs_out-stloc.
zst_item-matnr = gs_out-matnr.
zst_item-sout = gs_out-sout.
zst_item-sret = gs_out-sret.
zst_item-phclst = gs_out-phclst.
endmodule.
process after input.
module exit_9100.
loop at gt_out.
module modify_table_ctrl.
module user_command_9100.
endloop.
****************************************************
**------------- PAI ( screen 9100 ) --------------**
****************************************************
module exit_9100 input.
case ok_code1.
when 'EXIT'.
leave program.
when others.
endcase.
endmodule.
----------------------------------------------------------------------------------------------
module modify_table_ctrl input.
read table gt_out into gs_out index tab_ctrl-current_line.
if sy-subrc = 0.
modify gt_out index tab_ctrl-current_line from gs_out.
endif.
endmodule.
----------------------------------------------------------------------------------------------
module user_command_9100 input.
case ok_code1.
when 'SAVE'.
gs_save-phclst = zst_item-phclst.
modify zst_item.
message: 'Data Saved' type 'S'.
when others.
endcase.
endmodule.
-----------------------------------------------------------------------------------------
i need to enter values to 6th column.
thanks
2015 Jun 15 8:31 AM
2015 Jun 15 8:52 AM
CODE
process BEFORE OUPUT.
loop at gt_out into gs_out with control tab_ctrl.
endloop.
process after input.
loop at gt_out into gs_out with control tab_ctrl.
module user_command_9100.
ENDLOOP.
module user_command_9100 input.
case ok_code1.
when 'SAVE'.
zst_item-sdat = gs_out-sdat.
zst_item-werks = gs_out-werks.
zst_item-stloc = gs_out-stloc.
zst_item-matnr = gs_out-matnr.
zst_item-sout = gs_out-sout.
zst_item-sret = gs_out-sret.
zst_item-phclst = gs_out-phclst.
gs_save-phclst = zst_item-phclst.
modify zst_item.
message: 'Data Saved' type 'S'.
endcase.
endmodule.
2015 Jun 15 7:15 AM
hi Pramod,
I think in pbo u need to use describe statement becoz it needs to know the no of lines in your table control.
The best way to avoid this problem is to try table control with wizard as suggested by swadhin as it will handle all the controls. I suggest you to try table control with wizard once so that it helps you.
Thanks and Regards,
Sandeep.
2015 Jun 15 7:18 AM
Hi Sandeep,
I have already used Table control wizard, but that also has same problem,
I checked program ' demo_dynpro_tabcont_loop ' - when i m scrolling data not refreshed, but scroll more, time out will occur.
please advice .
thanks
2015 Jun 15 10:31 AM
Hi All,
Thanks for given support to fix above issue, i have check the demo_dynpro_tabcont_loop sample program and according to that i have done the changes in my coding.
Thanks
pramod