<?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 Re: Table control attribute change in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038901#M1171791</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Say if you have button DISPLAY and CHANGE to swap the modes of the fields, then you need to check the sy-ucomm and then use the earlier code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
CASE sy-ucomm.
  WHEN 'CHANGE'.
    loop at screen.
      if screen-group1 = 'ABC'.
        screen-input = 1.  " to change the mode of textbox as change mode
        screen-active = 1.
      endif.
      modify screen.
    endloop.
  WHEN 'DISPLAY'
    loop at screen.
      if screen-group1 = 'ABC'.
        screen-input = 0.  " to change the mode of textbox as display mode
        screen-active = 0.
      endif.
      modify screen.
    endloop.
ENDCASE.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this solves your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Tarun Gambhir&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 06 Jan 2009 10:14:58 GMT</pubDate>
    <dc:creator>I355602</dc:creator>
    <dc:date>2009-01-06T10:14:58Z</dc:date>
    <item>
      <title>Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038896#M1171786</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi experts,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a table control on a screen, and I have a Display/Change button. I want to change the attributes according to this button. &lt;/P&gt;&lt;P&gt;I try to do the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;      IF screen-group1 = 'G1'.&lt;/P&gt;&lt;P&gt;        screen-input = 1.&lt;/P&gt;&lt;P&gt;        screen-display_3d = 1.&lt;/P&gt;&lt;P&gt;        MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I execute the program, no matter wheter it is a change or display mode, the attributes do not change on screen. However I can see the change in debuge mode, the screen parameters are set to 1 (input, display_3d).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Jan 2009 09:41:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038896#M1171786</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-06T09:41:26Z</dc:date>
    </item>
    <item>
      <title>Re: Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038897#M1171787</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Say for a set of textboxes you take group1 in their attributes as &lt;STRONG&gt;'ABC'&lt;/STRONG&gt;, and on some condition you want to switch their mode from CHANGE/DISPLAY and vice-a-versa.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use it this way, its working:-&lt;/P&gt;&lt;P&gt;In PBO of screen.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
if &amp;lt;condition&amp;gt;.
  loop at screen.
    if screen-group1 = 'ABC'.
      screen-input = 0.  " to change the mode of textbox as display mode
      screen-active = 0.
    endif.
    modify screen.
  endloop.
elseif &amp;lt;condition&amp;gt;.
  loop at screen.
    if screen-group1 = 'ABC'.
      screen-input = 1.  " to change the mode of textbox as change mode
      screen-active = 1.
    endif.
    modify screen.
  endloop.
endif.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this solves your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Tarun Gambhir&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Jan 2009 09:51:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038897#M1171787</guid>
      <dc:creator>I355602</dc:creator>
      <dc:date>2009-01-06T09:51:41Z</dc:date>
    </item>
    <item>
      <title>Re: Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038898#M1171788</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Tarun,&lt;/P&gt;&lt;P&gt;I set the group on the screen before, I set the attributes also, but my code has no effect :'(&lt;/P&gt;&lt;P&gt;Maybe I'm wrong, but I don't know what could be the solution to fix the program.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Jan 2009 09:59:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038898#M1171788</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-06T09:59:23Z</dc:date>
    </item>
    <item>
      <title>Re: Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038899#M1171789</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In attributes for textbox controls that you have placed on the screen, take group1 as &lt;STRONG&gt;'ABC'&lt;/STRONG&gt; i.e., for all fields whose mode neeed to be changed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See if it works, or provide me with your code.&lt;/P&gt;&lt;P&gt;I will try and solve ASAP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Tarun Gambhir&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Jan 2009 10:02:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038899#M1171789</guid>
      <dc:creator>I355602</dc:creator>
      <dc:date>2009-01-06T10:02:39Z</dc:date>
    </item>
    <item>
      <title>Re: Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038900#M1171790</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i think that you have two transaction one is for display and second is for change.. right???&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so for this&lt;/P&gt;&lt;P&gt;for transaction &lt;STRONG&gt;display&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this module should be in pbo&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;module DEACTIVATE output.&lt;/P&gt;&lt;P&gt;if sy-tcode = 'ZDISPLAY' &amp;gt;&amp;gt;&amp;gt;&amp;gt; name of transaction&lt;/P&gt;&lt;P&gt;  LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;    IF SCREEN-GROUP1 = 'G1'.&lt;/P&gt;&lt;P&gt;      SCREEN-INPUT = 0.&lt;/P&gt;&lt;P&gt;      MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;      ENDLOOP.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;endmodule.   &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for &lt;STRONG&gt;change&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-tcode = 'ZCHANGE' &amp;gt;&amp;gt;&amp;gt;&amp;gt; name of transaction&lt;/P&gt;&lt;P&gt;  LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;    IF SCREEN-GROUP1 = 'G1'.&lt;/P&gt;&lt;P&gt;      SCREEN-INPUT = 1 .  &lt;/P&gt;&lt;P&gt;      MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;      ENDLOOP.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;endmodule. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope it helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;revert me back if u have ny queries&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;Sachin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Jan 2009 10:10:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038900#M1171790</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-06T10:10:33Z</dc:date>
    </item>
    <item>
      <title>Re: Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038901#M1171791</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Say if you have button DISPLAY and CHANGE to swap the modes of the fields, then you need to check the sy-ucomm and then use the earlier code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
CASE sy-ucomm.
  WHEN 'CHANGE'.
    loop at screen.
      if screen-group1 = 'ABC'.
        screen-input = 1.  " to change the mode of textbox as change mode
        screen-active = 1.
      endif.
      modify screen.
    endloop.
  WHEN 'DISPLAY'
    loop at screen.
      if screen-group1 = 'ABC'.
        screen-input = 0.  " to change the mode of textbox as display mode
        screen-active = 0.
      endif.
      modify screen.
    endloop.
ENDCASE.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this solves your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Tarun Gambhir&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Jan 2009 10:14:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038901#M1171791</guid>
      <dc:creator>I355602</dc:creator>
      <dc:date>2009-01-06T10:14:58Z</dc:date>
    </item>
    <item>
      <title>Re: Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038902#M1171792</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have the MODIFY SCREEN statement, and in DEBUG mode it seems to set it, but nothing has changed on the screen. It can be set somewhere else also? I don't understand because I have simple input fields on the screen also, and in case of them the Change/display is working properly.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Jan 2009 10:44:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038902#M1171792</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-06T10:44:46Z</dc:date>
    </item>
    <item>
      <title>Re: Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038903#M1171793</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are using table control, you can only enable/disable the columns for the records.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can't enable/disable a row to edit or display.&lt;/P&gt;&lt;P&gt;Either all fields for all records will be in display or change mode.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But you can definitely enable/disable common columns for all the records in the table control.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So its advisable that when you swap the mode, then in change mode keep the primary key fields of the table in display mode and apply change mode to other columns using the above code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And disable input when you click display button i.e., input = 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this solves your problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Tarun Gambhir&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Jan 2009 11:00:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038903#M1171793</guid>
      <dc:creator>I355602</dc:creator>
      <dc:date>2009-01-06T11:00:36Z</dc:date>
    </item>
    <item>
      <title>Re: Table control attribute change</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038904#M1171794</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, 13 Jan 2009 09:33:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/table-control-attribute-change/m-p/5038904#M1171794</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-13T09:33:24Z</dc:date>
    </item>
  </channel>
</rss>

