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

Table Control Data Not Save

former_member203806
Participant
0 Likes
1,855

Hi All,

When I am using table control with three cloumns (material, type & Max.Length ).

When the table control loading time both material & material type data will loaded and Max.Length column is input as manual entry.

In My Table control available 13 lines and my internal table has 20 lines.

When Im Scorll down and get display last two rows and do manual entry.

Only save Last tow rows (Table control  Displaying rows only ). 

i need to save all 20 recoreds.

Case:

I have 13 rows in Table control.

Output internal table has 20 Rows.

scorll down till last two rows and Click save.

save Only displaying last two records..

Screen

process before output.


   module status_0100.

   loop at itab into zmara_conn with control tab_ctrl.

   endloop.

process after input.

   loop at itab.

    MODULE read_table_control.

     module user_command_0100.

   endloop.



*********** PBO **********************

module status_0100 output.


   set pf-status 'SCREEN_100'.

   describe table itab lines fill.

   tab_ctrl-lines = fill.

endmodule.                 " STATUS_0100  OUTPUT



******** PAI ***************************


module read_table_control input.

   lines = sy-loopc.

   modify itab from zmara_conn index tab_ctrl-current_line.

endmodule.




module user_command_0100 input.

   case ok_code.

     when 'SAVE'.

       gs_save-matnr = zmara_conn-matnr.

       append gs_save to gt_save.

     when others.

   endcase.

endmodule

1 ACCEPTED SOLUTION
Read only

Chintu6august
Contributor
0 Likes
1,460

Hi,

IN PBO :

DESRCIBE TABLE itabl LINES tab_ctrl-lines.

  loop at itab into zmara_conn with control tab_ctrl CURSOR tab_ctrl-CURRENT_LINE.

  endloop.



IN PAI :


process after input.

   loop at itab.

    MODULE read_table_control.

   endloop.


  module user_command_0100.



module read_table_control input.

lines = sy-loopc.

   modify itab from zmara_conn index tab_ctrl-current_line TRANSPORTING  <Fieldnames>.

endmodule.



  module user_command_0100.

   case ok_code.

     when 'SAVE'.

    LOOP AT IT_TAB INTO ZMARA_CONN.

   gs_save-matnr = zmara_conn-matnr.

       append gs_save to gt_save.

    ENDLOOP.

     when others.

   endcase.

endmodule.


thank you!!

5 REPLIES 5
Read only

Chintu6august
Contributor
0 Likes
1,461

Hi,

IN PBO :

DESRCIBE TABLE itabl LINES tab_ctrl-lines.

  loop at itab into zmara_conn with control tab_ctrl CURSOR tab_ctrl-CURRENT_LINE.

  endloop.



IN PAI :


process after input.

   loop at itab.

    MODULE read_table_control.

   endloop.


  module user_command_0100.



module read_table_control input.

lines = sy-loopc.

   modify itab from zmara_conn index tab_ctrl-current_line TRANSPORTING  <Fieldnames>.

endmodule.



  module user_command_0100.

   case ok_code.

     when 'SAVE'.

    LOOP AT IT_TAB INTO ZMARA_CONN.

   gs_save-matnr = zmara_conn-matnr.

       append gs_save to gt_save.

    ENDLOOP.

     when others.

   endcase.

endmodule.


thank you!!

Read only

0 Likes
1,460

Hi

Is this program works vertical Scorll bars perfectly.

Read only

0 Likes
1,460

I hope Scroll bar is not a problem, logic is missing.

Read only

0 Likes
1,460

yes!!

Read only

0 Likes
1,460

Hi,

Above code is working properly. Thank you very much.