<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Manually Table Control in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576087#M1271827</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt; Can u Tell Me Which Things Should Take Care ,while trying to make a table control&lt;/P&gt;&lt;P&gt; Manually. i.e Code thts must be there in PBO ,PAI.??&lt;/P&gt;&lt;P&gt;thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 09 May 2009 06:01:58 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-05-09T06:01:58Z</dc:date>
    <item>
      <title>Manually Table Control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576087#M1271827</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt; Can u Tell Me Which Things Should Take Care ,while trying to make a table control&lt;/P&gt;&lt;P&gt; Manually. i.e Code thts must be there in PBO ,PAI.??&lt;/P&gt;&lt;P&gt;thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 May 2009 06:01:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576087#M1271827</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-09T06:01:58Z</dc:date>
    </item>
    <item>
      <title>Re: Manually Table Control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576088#M1271828</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I suggest you to read the relevant documents or take a training session on the same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;pk&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 May 2009 06:03:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576088#M1271828</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-09T06:03:18Z</dc:date>
    </item>
    <item>
      <title>Re: Manually Table Control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576089#M1271829</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Amit,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;pls read the content &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;TABLE CONTROL&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;In SE51 CREATE A TABLE control screen element.  Data in table contro can be accessed using loop statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;u need to declare a contro variable TYPE TableView using CONTROLS statement in ABAP Program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use LOOP ...ENDLOOP in both PBO &amp;amp; PAI &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF AT int_table parameter is not used than we have to place a MODULE call between the LOOP...ENDLOOP statement to fill the screen table rows from the ABAP program in PBO and program our own scrolling functions&lt;/P&gt;&lt;P&gt;using OK_CODE field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Having a parallel loop(at screen table rows &amp;amp; int table rows) by using parameter&lt;/P&gt;&lt;P&gt;AT int_table makes the ABAP code simple.&lt;/P&gt;&lt;P&gt;A special structure of type CXTAB_CONTROL is used to set/get various&lt;/P&gt;&lt;P&gt;attributes of table control at runtime like CURRENT_LINE ,TOP_LINE.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ABAP declaration&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;CONTROLS: tab_con TYPE TABLEVIEW  USING SCREEN nnnn&lt;/P&gt;&lt;P&gt;  Here tab_con is the same name we used in screen for the table control.&lt;/P&gt;&lt;P&gt;This ABAP statement will declare a control variable that will be used to access&lt;/P&gt;&lt;P&gt;the table control ,  and set it's various attributes like number of fixed columns(tab_con-FIXED_COLS) ,total number of records it will display(tab_con-LINES).It is of type CXTAB_CONTROL and is a deep structure(structure containing structures).&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;REFRESH CONTROL  tab_con FROM SCREEN nnnn&lt;/P&gt;&lt;P&gt; This ABAP statement will initialize the table control on the screen nnnn to its initial values.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;PBO processing&lt;/P&gt;&lt;P&gt;In PBO we have to use the screen LOOP ...ENDLOOP statement , with or without&lt;/P&gt;&lt;P&gt;intenal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

LOOP WITH  CONTROL tab_con.
   MODULE fill_tab_con.
   ENDLOOP.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here a module should be called between the &lt;STRONG&gt;loop endloop&lt;/STRONG&gt; statement to transfer&lt;/P&gt;&lt;P&gt;data from th ABAP program to the screen table through a structure.This module&lt;/P&gt;&lt;P&gt;should use the CURRENT_LINE attribute of the table control variable to get the&lt;/P&gt;&lt;P&gt;current screen table record index to read the data from the internal table into a work area.&lt;/P&gt;&lt;P&gt;e.g.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;READ TABLE int_table INDEX tab_con-CURRENT_LINE&lt;/P&gt;&lt;P&gt;The record read will be placed in the header line of the internal table and will be available to the similarly named  screen fields or if these are different it can be written explicitly. e.g.&lt;/P&gt;&lt;P&gt;screen_field_name = int_table-field_name&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;   &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

LOOP AT int_table INTO workarea WITH CONTROL tab_con CURSOR i FROM 
   n1 TO n2.
   ENDLOOP.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here the module call is not required to fill the screen table.The CURSOR parameter is a integer of type I indicating which absolute internal table line&lt;/P&gt;&lt;P&gt;should be the first to display on the table control .FROM n1 TO n2 can be used&lt;/P&gt;&lt;P&gt;to restrict the starting line and ending line number of the internal table , they are of type SY-TABIX.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;In both cases before the LOOP statement a module should be called which&lt;/P&gt;&lt;P&gt;is generally for setting of status ,in which we should fill the LINES attribute&lt;/P&gt;&lt;P&gt;(tab_con-LINES ) of the control with the total number of internal table records,doing this ensures correct and automatic scrolling.&lt;/P&gt;&lt;P&gt;The ABAP statement DESCRIBE TABLE int_table LINES lines can be used&lt;/P&gt;&lt;P&gt;to get the total lines in an int table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;PAI Processing&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; We have to use LOOP ... ENDLOOP in PAI so that data can transfer fro table control to ABAP program. If we want to write changes to the data we should&lt;/P&gt;&lt;P&gt;call a module between the LOOP ... ENDLOOP. The MODULE call to process user commands (SY-UCOM) should be called after the ENDLOOP statement.&lt;/P&gt;&lt;P&gt;e.g.&lt;/P&gt;&lt;P&gt;PROCESS AFTER INPUT&lt;/P&gt;&lt;P&gt;MODULE mod AT EXIT-COMMAND.&lt;/P&gt;&lt;P&gt;LOOP AT itab_table   or LOOP "depending on whether we are using AT int_table&lt;/P&gt;&lt;P&gt;MODULE modify_int_table.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;MODULE user_command.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;In the MODULE call modify_int_table we can use&lt;/P&gt;&lt;P&gt;MODIFY int_table FROM workarea INDEX tab_con-CURRENT_LINE&lt;/P&gt;&lt;P&gt;or we can use&lt;/P&gt;&lt;P&gt;int_table-field_name = screen_field_name.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 09 May 2009 06:34:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576089#M1271829</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-05-09T06:34:42Z</dc:date>
    </item>
    <item>
      <title>Re: Manually Table Control</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576090#M1271830</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Nov 2009 05:40:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/manually-table-control/m-p/5576090#M1271830</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-11-03T05:40:48Z</dc:date>
    </item>
  </channel>
</rss>

