<?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: How to modify dynamic internal table? in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634158#M1091243</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;if you know the component name or index then you can do that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;field-symbols: &amp;lt;fs&amp;gt; .

Loop at &amp;lt;dynamictable&amp;gt; into &amp;lt;dynamic_wa&amp;gt;.
if ...
assign component 'ROWCOLOR' of structure &amp;lt;dynamic_wa&amp;gt; to &amp;lt;fs&amp;gt;.
&amp;lt;fs&amp;gt; = 'C610'.

else.
assign component 'ROWCOLOR' of structure &amp;lt;dynamic_wa&amp;gt; to &amp;lt;fs&amp;gt;.
&amp;lt;fs&amp;gt; = ' '.
endif.
append &amp;lt;dynamic_wa&amp;gt; to &amp;lt;alv_outtab&amp;gt;.
endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 27 Oct 2008 16:39:30 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-10-27T16:39:30Z</dc:date>
    <item>
      <title>How to modify dynamic internal table?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634157#M1091242</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;i am using the concept of dynamic table to transpose an internal tabel and create an dynamic ALV.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The dynamic table has also layout fields to set the row color depending on the content.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now, after the first internal table is transposed and ready to display in ALV i would like to loop over the dynamic internal table and set the value for the row color.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Therefor i need your help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The "concept" of my idea is as the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Loop at &amp;lt;dynamictable&amp;gt; into &amp;lt;dynamic_wa&amp;gt;.&lt;/P&gt;&lt;P&gt;  if ...&lt;/P&gt;&lt;P&gt;     &amp;lt;dynamic_wa&amp;gt;-rowcolor = 'C610'.&lt;/P&gt;&lt;P&gt;  else.&lt;/P&gt;&lt;P&gt;     &amp;lt;dynamic_wa&amp;gt;-rowcolor = ' '.&lt;/P&gt;&lt;P&gt;  endif.&lt;/P&gt;&lt;P&gt;append &amp;lt;dynamic_wa&amp;gt; to &amp;lt;alv_outtab&amp;gt;.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Based on a condition i like to set a particular value in the componet rowcolor of the structure &amp;lt;dynamic_wa&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But i have no idea how to catch the components of dynamic tables to modify them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could anyone please assist me in this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Ralf&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Oct 2008 16:34:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634157#M1091242</guid>
      <dc:creator>ralf_vath</dc:creator>
      <dc:date>2008-10-27T16:34:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to modify dynamic internal table?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634158#M1091243</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;if you know the component name or index then you can do that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;field-symbols: &amp;lt;fs&amp;gt; .

Loop at &amp;lt;dynamictable&amp;gt; into &amp;lt;dynamic_wa&amp;gt;.
if ...
assign component 'ROWCOLOR' of structure &amp;lt;dynamic_wa&amp;gt; to &amp;lt;fs&amp;gt;.
&amp;lt;fs&amp;gt; = 'C610'.

else.
assign component 'ROWCOLOR' of structure &amp;lt;dynamic_wa&amp;gt; to &amp;lt;fs&amp;gt;.
&amp;lt;fs&amp;gt; = ' '.
endif.
append &amp;lt;dynamic_wa&amp;gt; to &amp;lt;alv_outtab&amp;gt;.
endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Oct 2008 16:39:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634158#M1091243</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-27T16:39:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to modify dynamic internal table?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634159#M1091244</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;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: FIELD-SYMBOLS: &amp;lt;FIELD1&amp;gt; TYPE ANY,
                                      &amp;lt;COLOR&amp;gt; TYPE ANY.

LOOP AT &amp;lt;DYNAMICTABLE&amp;gt; ASSIGNING &amp;lt;DYNAMIC_WA&amp;gt;.
   
    ASSIGN COMPONENT &amp;lt;FIELD NAME&amp;gt; OF STRUCTURE &amp;lt;DYNAMIC_WA&amp;gt; TO &amp;lt;FIELD1&amp;gt;.
    ASSIGN COMPONENT 'ROWCOLOR' OF STRUCTURE &amp;lt;DYNAMIC_WA&amp;gt; TO &amp;lt;COLOR&amp;gt;. 
    
    IF &amp;lt;FIELD1&amp;gt; = ......
      &amp;lt;COLOR&amp;gt; = 'C610'.
   ELSE.
     CLEAR &amp;lt;COLOR&amp;gt;.
  ENDIF. 
  APPEND &amp;lt;DYNAMIC_WA&amp;gt; TO &amp;lt;ALV_OUTTAB&amp;gt;.
ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Oct 2008 16:41:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634159#M1091244</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-27T16:41:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to modify dynamic internal table?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634160#M1091245</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;issue :&lt;/P&gt;&lt;P&gt;i have created a dynamic internal table(dyn_tab) and a dynamic work area (dyn_wa).&lt;/P&gt;&lt;P&gt;1. actually i have to calculate some data and then insert the same in to the dynamic table .&lt;/P&gt;&lt;P&gt;ex:&lt;/P&gt;&lt;P&gt;if suppose i have 10 fields in my dynamic table.&lt;/P&gt;&lt;P&gt;and my field names are suppose from 0 to 10 .(wil be created at run time)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;iam not able to write " &amp;lt;dyn_wa&amp;gt;-0 = 'help'. " (it is showing an syntax error because the structure is created dynamically which does not have that field name befor the program is executed )&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;("I WANT TO APPEND A RECORD IN TO DYNAMIC INTERNAL TABLE ")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"PLEASE HELP ME "&lt;/P&gt;&lt;P&gt;please help me out regarding this issue i hope u can do this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WATING.&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;shivkanth&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 Jan 2009 04:38:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-modify-dynamic-internal-table/m-p/4634160#M1091245</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-01-22T04:38:59Z</dc:date>
    </item>
  </channel>
</rss>

