<?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: Appending Objects in an internal Table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148918#M1368141</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Declare a field in the table with&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
    oref           type ref to ZCL_MY_CLASS,
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and store your object in it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 02 Sep 2009 13:55:03 GMT</pubDate>
    <dc:creator>rainer_hbenthal</dc:creator>
    <dc:date>2009-09-02T13:55:03Z</dc:date>
    <item>
      <title>Appending Objects in an internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148915#M1368138</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hallo Guru,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm looking for a way to append newly created objects of a class "XYZ" in an internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Kais&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Sep 2009 13:46:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148915#M1368138</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-02T13:46:03Z</dc:date>
    </item>
    <item>
      <title>Re: Appending Objects in an internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148916#M1368139</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Can you elaborate your query in details?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ankur Parab&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Sep 2009 13:49:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148916#M1368139</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-02T13:49:30Z</dc:date>
    </item>
    <item>
      <title>Re: Appending Objects in an internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148917#M1368140</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Ankur,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've created a new class.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And now I created a Progam which 2 or 3 instances of this class has been created, using CREATE OBJECT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I put some information on it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now, I want to use an internal table, which ref to my class.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I want to save every instance with its information in the internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, later I'm going to loop over the internal table to print out the information.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kais&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Sep 2009 13:54:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148917#M1368140</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-02T13:54:28Z</dc:date>
    </item>
    <item>
      <title>Re: Appending Objects in an internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148918#M1368141</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Declare a field in the table with&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
    oref           type ref to ZCL_MY_CLASS,
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and store your object in it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Sep 2009 13:55:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148918#M1368141</guid>
      <dc:creator>rainer_hbenthal</dc:creator>
      <dc:date>2009-09-02T13:55:03Z</dc:date>
    </item>
    <item>
      <title>Re: Appending Objects in an internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148919#M1368142</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Kais&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you already on ECC 6.0 then you may have a look at the iterator class &lt;STRONG&gt;SWF_UTL_OBJECT_TAB&lt;/STRONG&gt;. An appropriate table type for you would be &lt;STRONG&gt;SWF_UTL_OBJECT_TAB&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;  Uwe&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Sep 2009 13:58:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148919#M1368142</guid>
      <dc:creator>uwe_schieferstein</dc:creator>
      <dc:date>2009-09-02T13:58:48Z</dc:date>
    </item>
    <item>
      <title>Re: Appending Objects in an internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148920#M1368143</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;Thanks for your Respond.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I actually looking for is how to insert the object in the table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This's how it looks like.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

DATA : it_employees TYPE TABLE OF REF TO lcl_employee WITH HEADER LINE,
             r_employee TYPE REF TO lcl_employee.

START-OF-SELECTION.

  CREATE OBJECT r_employee
    EXPORTING
      im_name        = '******'
      im_firstname   = '*****'
      im_base_salary = 1000
      im_dob         = '******'.

  r_employee-&amp;gt;set_address( im_address = '*******' ).

*???? How to insert the Object in The table

  LOOP AT it_employees.
    it_employees-&amp;gt;print( ).
  ENDLOOP.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Kais&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Sep 2009 14:10:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148920#M1368143</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-02T14:10:38Z</dc:date>
    </item>
    <item>
      <title>Re: Appending Objects in an internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148921#M1368144</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;U need to append the object in the table like a normal workarea:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CLASS LC_MY_CLASS DEFINITION.
  PUBLIC SECTION.
    METHODS: CONSTRUCTOR
              IMPORTING P_NAME TYPE CHAR20,
             WRITE_NAME.
  PRIVATE SECTION.
    DATA: NAME TYPE CHAR20.
ENDCLASS.                    "LC_MY_CLASS DEFINITION

CLASS LC_MY_CLASS IMPLEMENTATION.
  METHOD CONSTRUCTOR.
    NAME = P_NAME.
  ENDMETHOD.                    "CONSTRUCTOR

  METHOD WRITE_NAME.
    WRITE: / NAME.
  ENDMETHOD.                    "WRITE_NAME
ENDCLASS.                    "LC_MY_CLASS IMPLEMENTATION

TYPES: TY_OBJ TYPE REF TO LC_MY_CLASS.

DATA: MY_OBJ TYPE REF TO LC_MY_CLASS,
      T_OBJ  TYPE TABLE OF TY_OBJ.

START-OF-SELECTION.

  CREATE OBJECT MY_OBJ
    EXPORTING
      P_NAME = 'MAX'.

  APPEND MY_OBJ TO T_OBJ.

  CREATE OBJECT MY_OBJ
    EXPORTING
      P_NAME = 'MAX 2'.

  APPEND MY_OBJ TO T_OBJ.

  LOOP AT T_OBJ INTO MY_OBJ.
    CALL METHOD MY_OBJ-&amp;gt;WRITE_NAME.
  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>Wed, 02 Sep 2009 14:15:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148921#M1368144</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-02T14:15:11Z</dc:date>
    </item>
    <item>
      <title>Re: Appending Objects in an internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148922#M1368145</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Max.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I has solved the Problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Sep 2009 14:21:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/appending-objects-in-an-internal-table/m-p/6148922#M1368145</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-02T14:21:43Z</dc:date>
    </item>
  </channel>
</rss>

