<?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: Assign component with table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086237#M99382</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;assign local copy solved it too, but is not allowed in OO context.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yours is the solution except that&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
  CREATE DATA dref like line of datatable. 
  ASSIGN dref-&amp;gt;* TO &amp;lt;fs&amp;gt;.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is the 100% solution &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Otherwise youre getting problems with &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
  insert &amp;lt;fs&amp;gt; into table datatable.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot to you both.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 03 Nov 2005 13:42:42 GMT</pubDate>
    <dc:creator>rainer_hbenthal</dc:creator>
    <dc:date>2005-11-03T13:42:42Z</dc:date>
    <item>
      <title>Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086228#M99373</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have problem with assign component:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in a method, i have an exporting parameter type any table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Therefore i do not know the structure of this. Now i want to fill this table with&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
  assign component 1 of structure it_example[] to &amp;lt;p&amp;gt;.

  &amp;lt;p&amp;gt; = "xyz".
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Having a structure this is no problem, but a table is not a structure and therefore im getting result code of 4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Outsite methods i can use tables with headerlines, and the headerline has a structure so with the assign i can fill the header line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In OO context, tables with headerlines are not allowed. So how can i fill the table if i do not have a glue what the structure looks like? Any idea?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:04:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086228#M99373</guid>
      <dc:creator>rainer_hbenthal</dc:creator>
      <dc:date>2005-11-03T13:04:11Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086229#M99374</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Rainer,&lt;/P&gt;&lt;P&gt;i think you have to define a structure and use this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;E.g.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data wa_example type "same type of it_example".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use the assign with this structure, and after append it to the table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bye&lt;/P&gt;&lt;P&gt;enzo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:07:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086229#M99374</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-11-03T13:07:10Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086230#M99375</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;try with this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;assign component 1 of structure it_example to &amp;lt;p&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers,&lt;/P&gt;&lt;P&gt;sasi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:08:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086230#M99375</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-11-03T13:08:55Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086231#M99376</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I really want to avoid haveing an additional paramter in the siganture of the method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

DATA:

 wa_internal like line of &amp;lt;imported_table&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;didnt worked either &lt;SPAN __jive_emoticon_name="sad"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:10:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086231#M99376</guid>
      <dc:creator>rainer_hbenthal</dc:creator>
      <dc:date>2005-11-03T13:10:52Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086232#M99377</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Works neither -&amp;gt; sy-subrc = 4.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:11:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086232#M99377</guid>
      <dc:creator>rainer_hbenthal</dc:creator>
      <dc:date>2005-11-03T13:11:35Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086233#M99378</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;  Use something similar to the following,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  FIELD-SYMBOLS: &amp;lt;fs&amp;gt;, &amp;lt;fval&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN LOCAL COPY OF INITIAL LINE OF it_example&lt;/P&gt;&lt;P&gt;  TO &amp;lt;fs&amp;gt;. &lt;/P&gt;&lt;P&gt;  IF &amp;lt;fs&amp;gt; IS ASSIGNED.&lt;/P&gt;&lt;P&gt;    ASSIGN COMPONENT 1 OF STRUCTURE &amp;lt;fs&amp;gt; TO &amp;lt;fval&amp;gt;.&lt;/P&gt;&lt;P&gt;    IF &amp;lt;fval&amp;gt; IS ASSIGNED.&lt;/P&gt;&lt;P&gt;      &amp;lt;fval&amp;gt; = 'xyz'.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;    APPEND &amp;lt;fs&amp;gt; TO it_example.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  Hope this helps..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sri&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:12:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086233#M99378</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-11-03T13:12:37Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086234#M99379</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rainer,&lt;/P&gt;&lt;P&gt;         check with this code.Hope it works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT datatab.&lt;/P&gt;&lt;P&gt;    DO.&lt;/P&gt;&lt;P&gt;      ASSIGN COMPONENT sy-index OF STRUCTURE &lt;/P&gt;&lt;P&gt;                                    datatab TO &amp;lt;fs&amp;gt;.&lt;/P&gt;&lt;P&gt;      IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;        EXIT.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDDO.&lt;/P&gt;&lt;P&gt;  ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward me if this works.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Vamsi.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:13:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086234#M99379</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-11-03T13:13:50Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086235#M99380</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;as you want to fill the table - not any non-existing header line, you must populate the table record by record, that means LOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;field-symbols:&lt;/P&gt;&lt;P&gt;  &amp;lt;fs&amp;gt; type any.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at it_example assigning &amp;lt;fs&amp;gt;.&lt;/P&gt;&lt;P&gt;  assign component 1 of structure &amp;lt;fs&amp;gt; to &amp;lt;p&amp;gt;.&lt;/P&gt;&lt;P&gt;  &amp;lt;p&amp;gt; = "xyz".&lt;/P&gt;&lt;P&gt;endloop." at it_example assigning &amp;lt;fs&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;fast. efficient.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;C.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:16:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086235#M99380</guid>
      <dc:creator>Clemenss</dc:creator>
      <dc:date>2005-11-03T13:16:21Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086236#M99381</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rainer,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use this format.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: dref TYPE REF TO DATA. &lt;/P&gt;&lt;P&gt;FIELD-SYMBOLS: &amp;lt;fs&amp;gt; TYPE ANY. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CREATE DATA dref TYPE &amp;lt;table&amp;gt;. &lt;/P&gt;&lt;P&gt;ASSIGN dref-&amp;gt;* TO &amp;lt;fs&amp;gt;. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here 'create data' creates anonymous data object of the table.The dref points to the work area of the table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then assign the workarea to the field symbol.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards.&lt;/P&gt;&lt;P&gt;Lavanya.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:23:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086236#M99381</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2005-11-03T13:23:10Z</dc:date>
    </item>
    <item>
      <title>Re: Assign component with table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086237#M99382</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;assign local copy solved it too, but is not allowed in OO context.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yours is the solution except that&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
  CREATE DATA dref like line of datatable. 
  ASSIGN dref-&amp;gt;* TO &amp;lt;fs&amp;gt;.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is the 100% solution &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Otherwise youre getting problems with &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
  insert &amp;lt;fs&amp;gt; into table datatable.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot to you both.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Nov 2005 13:42:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/assign-component-with-table/m-p/1086237#M99382</guid>
      <dc:creator>rainer_hbenthal</dc:creator>
      <dc:date>2005-11-03T13:42:42Z</dc:date>
    </item>
  </channel>
</rss>

