<?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: Method call with dynamic types in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/method-call-with-dynamic-types/m-p/10669090#M1867939</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Tim,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check some of the standard methods are function modules from SAP like Function module GUI_DOWNLOAD with DATA_TAB parameter&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;Venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 13 Nov 2014 10:49:11 GMT</pubDate>
    <dc:creator>former_member206479</dc:creator>
    <dc:date>2014-11-13T10:49:11Z</dc:date>
    <item>
      <title>Method call with dynamic types</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/method-call-with-dynamic-types/m-p/10669088#M1867937</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 have created a method with 2 parameters:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i_struc&amp;nbsp;&amp;nbsp; type any&amp;nbsp;&amp;nbsp; (import)&lt;/P&gt;&lt;P&gt;ct_table type any table. (changing)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in my method call I have the types for the parameters defined already, so e.g.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: ls_struc type my_struc,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; lt_table&amp;nbsp; type standard table of my_struc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call method xyz&lt;/P&gt;&lt;P&gt;&amp;nbsp; exporting&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; i_struct = ls_struc&lt;/P&gt;&lt;P&gt;&amp;nbsp; changing&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; ct_table = lt_table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now in my method I need to refer to the types in the method call, so e.g. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ls_struc-field1 = 'ABC'.&lt;/P&gt;&lt;P&gt;ls_struc-field2 = 'DEF'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;append ls_struc to ct_table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But of course the ls_struc inside the method has no structure, so I am missing the part where the type from the method call can be used inside the method. The method logic should be generic because I will have different method calls with different types for structure and table. Do I need to use ASSIGN COMPONENT.....?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help is appreciated.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Tim &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Nov 2014 10:22:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/method-call-with-dynamic-types/m-p/10669088#M1867937</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2014-11-13T10:22:13Z</dc:date>
    </item>
    <item>
      <title>Re: Method call with dynamic types</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/method-call-with-dynamic-types/m-p/10669089#M1867938</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tim,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since you have not given the (static) structure type in the method declaration, I guess Assign component and dynamic programming is the only option left for you. You can get some help from the following post. Best of luck.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://wiki.scn.sap.com/wiki/display/ABAP/Dynamic+Internal+table?original_fqdn=wiki.sdn.sap.com" title="http://wiki.scn.sap.com/wiki/display/ABAP/Dynamic+Internal+table?original_fqdn=wiki.sdn.sap.com"&gt;Dynamic Internal table - ABAP Development - SCN Wiki&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Saurabh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Nov 2014 10:46:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/method-call-with-dynamic-types/m-p/10669089#M1867938</guid>
      <dc:creator>former_member543959</dc:creator>
      <dc:date>2014-11-13T10:46:58Z</dc:date>
    </item>
    <item>
      <title>Re: Method call with dynamic types</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/method-call-with-dynamic-types/m-p/10669090#M1867939</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Tim,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check some of the standard methods are function modules from SAP like Function module GUI_DOWNLOAD with DATA_TAB parameter&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;Venkat&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Nov 2014 10:49:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/method-call-with-dynamic-types/m-p/10669090#M1867939</guid>
      <dc:creator>former_member206479</dc:creator>
      <dc:date>2014-11-13T10:49:11Z</dc:date>
    </item>
  </channel>
</rss>

