‎2009 Mar 03 12:44 PM
My data from the top of the table control are disappearing when i press the horizontal scroll down.
Can someone help me?
‎2009 Mar 03 12:52 PM
Whenever you carry on a scrollbar movement(horizontal/vertical) ,the PBO of the respective screen get executed followed by a PAI execution.So check your code setting proper breakpoint at PBO module.
Thanks
‎2009 Mar 03 12:47 PM
You might have written some code for scroll bar, please check that once by mistake if you are doing something or Check in the properties of table control
‎2009 Mar 03 12:52 PM
Whenever you carry on a scrollbar movement(horizontal/vertical) ,the PBO of the respective screen get executed followed by a PAI execution.So check your code setting proper breakpoint at PBO module.
Thanks
‎2009 Mar 03 12:58 PM
Now check the PBO and PAI and i have not seen anything. There must be some code to this.
‎2009 Mar 04 4:05 AM
Hi
All you need to dos is to read the internal table into the table control in PBO of the screen.
Refer the below code:-
In PBO, you read internal table to table control on screen.
In PAI, you modify internal table from the table control on screen.
it_zekpo is my internal table w/o header line,
wa_zekpo is work area.
Name of input/output fields on screen are:-
wa_zekpo-field1,
wa_zekpo-field2, and so on...
Use code:-
At screen logic:-
PROCESS BEFORE OUTPUT.
* MODULE status_8003.
LOOP WITH CONTROL po_tab. "po_tab is table control on screen 8003
MODULE read_data.
ENDLOOP.
PROCESS AFTER INPUT.
* MODULE user_command_8003.
LOOP WITH CONTROL po_tab.
MODULE modify_data.
ENDLOOP.
In PBO:-
*&---------------------------------------------------------------------*
*& Module READ_DATA OUTPUT
*&---------------------------------------------------------------------*
MODULE read_data OUTPUT.
READ TABLE it_zekpo INTO wa_zekpo INDEX po_tab-current_line. "po_tab is table control name
" read the record from internal table to table control
data : line_count type i.
describe it_zekpo
lines line_count.
po_tab-lines = line_count + 10.
"to increase the number of lines in table control dynamically
ENDMODULE. " READ_DATA OUTPUT
In PAI:-
*&---------------------------------------------------------------------*
*& Module MODIFY_DATA INPUT
*&---------------------------------------------------------------------*
MODULE MODIFY_DATA INPUT.
MODIFY IT_ZEKPO FROM WA_ZEKPO INDEX po_tab-currentline.
"this will modify the contents of existing line
ENDMODULE. " MODIFY_DATA INPUT
Hope this solves your problem.
Thanks & Regards,
Tarun Gambhir
‎2009 Mar 03 12:54 PM
hello carlos,
kindly check the case,where u have written the code for table control data or scroll bar.
It is always good to use table control wizard,bcz there is one option for scroll bar in wizard.
Regards
‎2009 Mar 06 7:01 AM
create a module and write down the code :
DESCRIBE TABLE it_table LINES tabcntrl-lines.
Note: don't put the module in the loop and place it in such a way that before executing this statement it_table should be filledup with the data.
regards,
Nilay