<?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: Dynamic CREATE OBJECT with parameters REF TO interface. in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066028#M1969664</link>
    <description>&lt;P&gt;The problem is that you are using generic reference variables with type &lt;EM&gt;object&lt;/EM&gt; to access the instances you created and passing them to the constructor leads to type conflicts as the variable's static type is examined during runtime. Is there a specific reasons why you are avoiding interface types? This way it should be working:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA lt_tile_tm_combination TYPE /ui2/if_flp_cont_mgr=&amp;gt;tt_tile_tm_combination_sorted.
DATA lo_flp_cont_mgr TYPE REF TO /ui2/if_flp_cont_mgr.
DATA lo_catalog_api TYPE REF TO /ui2/if_fdm_catalog_api.
DATA lo_messaging TYPE REF TO /ui2/if_fcm_messaging.
DATA lx_root TYPE REF TO cx_root.

TRY.
    CREATE OBJECT lo_catalog_api TYPE ('/UI2/CL_FDM_CATALOG_API')
      EXPORTING
        iv_scope     = 'CUST' "or 'CONF'
        iv_use_cache = abap_true.
  CATCH cx_root INTO lx_root.
    MESSAGE lx_root TYPE 'E'.
ENDTRY.
CREATE OBJECT lo_messaging TYPE ('/UI2/CL_FCM_MESSAGING').
CREATE OBJECT lo_flp_cont_mgr TYPE ('/UI2/CL_FLP_CONT_MGR')
  EXPORTING
    iv_scope = 'CUST'
    io_catalog_api = lo_catalog_api
    io_messaging = lo_messaging.

lt_tile_tm_combination = lo_flp_cont_mgr-&amp;gt;get_all_tiles_tms( ).
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Other option would be to apply the CAST operator, if for some reason the variable types cannot be altered:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CREATE OBJECT lo_flp_cont_mgr TYPE ('/UI2/CL_FLP_CONT_MGR')
  EXPORTING
    iv_scope       = 'CUST'
    io_catalog_api = CAST /ui2/if_fdm_catalog_api( lo_catalog_api )
    io_messaging   = CAST /ui2/if_fcm_messaging( lo_messaging ).

lt_tile_tm_combination = CAST /ui2/if_flp_cont_mgr( lo_flp_cont_mgr )-&amp;gt;get_all_tiles_tms( ).
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 27 Dec 2019 21:50:22 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2019-12-27T21:50:22Z</dc:date>
    <item>
      <title>Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066027#M1969663</link>
      <description>&lt;P&gt;I'm trying to dynamically call the constructor of a class, where the parameters are with reference to an interface. However, I keep getting the dump DYN_CALL_METH_PARAM_TYPE, CX_SY_DYN_CALL_ILLEGAL_TYPE.&lt;/P&gt;
  &lt;P&gt; An attempt was made to pass a current parameter to formal parameter "IO_MESSAGING" of method "CONSTRUCTOR" of class "/UI2/CL_FLP_CONT_MGR". This resulted in a type conflict.&lt;BR /&gt;&lt;/P&gt;
  &lt;P&gt;I've tried using RTTS, CREATE DATA dat TYPE REF TO (classname), and I get the same error. Anyone have any ideas how to get this working. Sample code which demonstrates the issue is below. This is running on a 754, s4hana system.&lt;/P&gt;
  &lt;PRE&gt;&lt;CODE&gt;DATA lt_tile_tm_combination TYPE /ui2/if_flp_cont_mgr=&amp;gt;tt_tile_tm_combination_sorted.
DATA lo_flp_cont_mgr TYPE REF TO object. " /ui2/if_flp_cont_mgr.
DATA lo_catalog_api TYPE REF TO object.  " /ui2/if_fdm_catalog_api.
DATA lo_messaging TYPE REF TO object.    " /ui2/if_fcm_messaging.
DATA lx_root TYPE REF TO cx_root.
TRY.
    CREATE OBJECT lo_catalog_api TYPE ('/UI2/CL_FDM_CATALOG_API')
      EXPORTING
        iv_scope     = 'CUST' "or 'CONF'
        iv_use_cache = abap_true.
  CATCH cx_root INTO lx_root.
    MESSAGE lx_root TYPE 'E'.
ENDTRY.
CREATE OBJECT lo_messaging TYPE ('/UI2/CL_FCM_MESSAGING').
CREATE OBJECT lo_flp_cont_mgr TYPE ('/UI2/CL_FLP_CONT_MGR') "/ui2/cl_flp_cont_mgr
  EXPORTING
    iv_scope = 'CUST'
    io_catalog_api = lo_catalog_api " TYPE REF TO /UI2/IF_FDM_CATALOG_API
    io_messaging = lo_messaging.    " TYPE REF TO /UI2/IF_FCM_MESSAGING
CALL METHOD lo_flp_cont_mgr-&amp;gt;('/UI2/IF_FLP_CONTR_MGR~GET_ALL_TILES_TMS')
    RECEIVING rt_tile_tm_combination = lt_tile_tm_combination.
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 27 Dec 2019 19:41:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066027#M1969663</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2019-12-27T19:41:36Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066028#M1969664</link>
      <description>&lt;P&gt;The problem is that you are using generic reference variables with type &lt;EM&gt;object&lt;/EM&gt; to access the instances you created and passing them to the constructor leads to type conflicts as the variable's static type is examined during runtime. Is there a specific reasons why you are avoiding interface types? This way it should be working:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA lt_tile_tm_combination TYPE /ui2/if_flp_cont_mgr=&amp;gt;tt_tile_tm_combination_sorted.
DATA lo_flp_cont_mgr TYPE REF TO /ui2/if_flp_cont_mgr.
DATA lo_catalog_api TYPE REF TO /ui2/if_fdm_catalog_api.
DATA lo_messaging TYPE REF TO /ui2/if_fcm_messaging.
DATA lx_root TYPE REF TO cx_root.

TRY.
    CREATE OBJECT lo_catalog_api TYPE ('/UI2/CL_FDM_CATALOG_API')
      EXPORTING
        iv_scope     = 'CUST' "or 'CONF'
        iv_use_cache = abap_true.
  CATCH cx_root INTO lx_root.
    MESSAGE lx_root TYPE 'E'.
ENDTRY.
CREATE OBJECT lo_messaging TYPE ('/UI2/CL_FCM_MESSAGING').
CREATE OBJECT lo_flp_cont_mgr TYPE ('/UI2/CL_FLP_CONT_MGR')
  EXPORTING
    iv_scope = 'CUST'
    io_catalog_api = lo_catalog_api
    io_messaging = lo_messaging.

lt_tile_tm_combination = lo_flp_cont_mgr-&amp;gt;get_all_tiles_tms( ).
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Other option would be to apply the CAST operator, if for some reason the variable types cannot be altered:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CREATE OBJECT lo_flp_cont_mgr TYPE ('/UI2/CL_FLP_CONT_MGR')
  EXPORTING
    iv_scope       = 'CUST'
    io_catalog_api = CAST /ui2/if_fdm_catalog_api( lo_catalog_api )
    io_messaging   = CAST /ui2/if_fcm_messaging( lo_messaging ).

lt_tile_tm_combination = CAST /ui2/if_flp_cont_mgr( lo_flp_cont_mgr )-&amp;gt;get_all_tiles_tms( ).
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 27 Dec 2019 21:50:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066028#M1969664</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2019-12-27T21:50:22Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066029#M1969665</link>
      <description>&lt;P&gt;Sorry, I missed out a vital piece of information. The code must be syntactically correct in a 7.31 system that doesn't contain these classes and interfaces, &lt;STRONG&gt;and &lt;/STRONG&gt;actually run on the 7.54 system!. The types used in the data definitions don't exist in 7.31, but they're easy to replicate.&lt;/P&gt;</description>
      <pubDate>Sat, 28 Dec 2019 06:26:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066029#M1969665</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2019-12-28T06:26:04Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066030#M1969666</link>
      <description>&lt;P&gt;Sorry, I missed out a vital piece of information. The code must be syntactically correct in a 7.31 system that doesn't contain these classes and interfaces, &lt;STRONG&gt;and &lt;/STRONG&gt;actually run on the 7.54 system!. The types used in the data definitions don't exist in 7.31, but they're easy to replicate. don't exist in 7.31, but they're easy to replicate.&lt;/P&gt;</description>
      <pubDate>Sat, 28 Dec 2019 06:53:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066030#M1969666</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2019-12-28T06:53:59Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066031#M1969667</link>
      <description>&lt;P&gt;&lt;SPAN class="mention-scrubbed"&gt;matthew.billingham&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;So the codebase is common, but actually will run only on a higher release? The serious limitation here is even though everything can be done dynamically at source level type checks against references take place during execution. And there is no way to bypass that.&lt;/P&gt;&lt;P&gt;What about generating and calling a subroutine where the result is taken over from if the classes exist?&lt;/P&gt;&lt;P&gt;Or, if additional program objects are permitted on 7.54 outsource the release dependent logic to a class which is dynamically referenced from the common code.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;TRY.

  CALL METHOD ('ZCL_MY_HIGHER_RELEASE_STUFFS')=&amp;gt;('GET_RESULTS')
    RECEIVING results = results.

CATCH cx_sy_dyn_call_illegal_class.
  " Lower system version
ENDTRY.
&lt;BR /&gt;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 28 Dec 2019 08:26:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066031#M1969667</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2019-12-28T08:26:44Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066032#M1969668</link>
      <description>&lt;P&gt;I don't understand if there is still a question here.&lt;/P&gt;&lt;P&gt;This 7.40+ downcast statement:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA more_general TYPE REF TO object.
DATA(less_general) = CAST less_general_object_type( more_general ).&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;is equivalent to this code in releases before 7.40:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA more_general TYPE REF TO object.
DATA less_general TYPE REF TO less_general_object_type.
less_general ?= more_general.&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 28 Dec 2019 08:47:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066032#M1969668</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2019-12-28T08:47:47Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066033#M1969669</link>
      <description>&lt;P&gt; &lt;SPAN class="mention-scrubbed"&gt;sandra.rossi&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;As far as I understand the though part is that the source to be written cannot contain static reference to the interfaces, because it must compile also on lower release where those do not exist&lt;/P&gt;</description>
      <pubDate>Sat, 28 Dec 2019 09:02:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066033#M1969669</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2019-12-28T09:02:21Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066034#M1969670</link>
      <description>&lt;P&gt;  &lt;SPAN class="mention-scrubbed"&gt;sandra.rossi&lt;/SPAN&gt; It's because the &lt;EM&gt;less_general_object_type&lt;/EM&gt; doesn't exist in 7.31&lt;/P&gt;&lt;P&gt;The types are correct at runtime, so it's peculiar that it doesn't work on 7.4+.&lt;/P&gt;</description>
      <pubDate>Mon, 30 Dec 2019 07:19:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066034#M1969670</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2019-12-30T07:19:12Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066035#M1969671</link>
      <description>&lt;P&gt;Thanks, &lt;SPAN class="mention-scrubbed"&gt;gabmarian&lt;/SPAN&gt;, &lt;SPAN class="mention-scrubbed"&gt;matthew.billingham&lt;/SPAN&gt;, I understand now. I don't see an ABAP solution because it's an ABAP limitation: the short dump you get at runtime is equivalent to the syntax error if you use the static call of the method:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA lo_flp_cont_mgr TYPE REF TO /ui2/cl_flp_cont_mgr.
DATA lo_catalog_api TYPE REF TO object.
DATA lo_messaging TYPE REF TO object.
CREATE OBJECT lo_flp_cont_mgr
EXPORTING
iv_scope       = 'CUST'
io_catalog_api = lo_catalog_api "syntax error "LO_CATALOG_API" is not type-compatible with formal parameter "IO..."
io_messaging   = lo_messaging.  "syntax error "LO_MESSAGING" is not type-compatible with formal parameter "IO..." &lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Either you don't copy the code to the 7.31 system (several source systems) or you generate the source code at runtime (GENERATE SUBROUTINE POOL).&lt;/P&gt;</description>
      <pubDate>Mon, 30 Dec 2019 08:24:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066035#M1969671</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2019-12-30T08:24:31Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamic CREATE OBJECT with parameters REF TO interface.</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066036#M1969672</link>
      <description>&lt;P&gt;It's as &lt;SPAN class="mention-scrubbed"&gt;sandra.rossi&lt;/SPAN&gt; said - it can't be done using dynamic ABAP. The solution I've adopted is to generate the code of the method once at runtime. I've not included the method &lt;STRONG&gt;interface_exists&lt;/STRONG&gt;&lt;EM&gt;. &lt;/EM&gt;This can be implemented easily using the RTTS.&lt;/P&gt;&lt;P&gt;The first time the constructor of the class runs, the method &lt;STRONG&gt;get_all_tiles_tms&lt;/STRONG&gt; has its comment lines removed, but only if the interface &lt;STRONG&gt;/UI2/IF_FLP_CONT_MGR&lt;/STRONG&gt; exists.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CLASS zcl_dynamic_method_change_demo DEFINITION
  PUBLIC
  FINAL
  CREATE PUBLIC .

  PUBLIC SECTION.
    TYPES: tt_tile_tm_combination_sorted TYPE string_table. 
    " I'm using string_Table here. but for it work in our 754 system
    " we need to create our own Z version of the real type
    " /ui2/if_flp_cont_mgr=&amp;gt;tt_tile_tm_combination_sorted
    METHODS constructor .
    METHODS get_all_tiles_tms
      RETURNING
        value(r_result) TYPE tt_tile_tm_combination_sorted .
  PROTECTED SECTION.
  PRIVATE SECTION.
    METHODS method_not_initialised
      RETURNING
        value(r_result) TYPE abap_bool.
    METHODS initialise_method.
    METHODS strip_out_comments
      IMPORTING
        i_source_code   TYPE siw_tab_code
      RETURNING
        value(r_result) TYPE siw_tab_code.
ENDCLASS.

CLASS zcl_dynamic_method_change_demo IMPLEMENTATION.
  METHOD constructor.
    IF interface_exists( '/UI2/IF_FLP_CONT_MGR' ) EQ abap_false.
      MESSAGE 'Cannot be run on this system' TYPE 'E'.
    ENDIF.
    IF method_not_initialised( ) EQ abap_false.
      initialise_method( ).
      MESSAGE 'Please restart transaction. You should not see this message again'
         TYPE 'E'.
    ENDIF.
  ENDMETHOD.

  METHOD get_all_tiles_tms.
*    DATA lt_tile_tm_combination TYPE /ui2/if_flp_cont_mgr=&amp;gt;tt_tile_tm_combination_sorted.
*    DATA lo_flp_cont_mgr TYPE REF TO /ui2/if_flp_cont_mgr.
*    DATA lo_catalog_api TYPE REF TO /ui2/if_fdm_catalog_api.
*    DATA lo_messaging TYPE REF TO /ui2/if_fcm_messaging.
*    DATA lx_root TYPE REF TO cx_root.
*    TRY.
*        CREATE OBJECT lo_catalog_api TYPE /ui2/cl_fdm_catalog_api
*          EXPORTING
*            iv_scope     = 'CUST' "or 'CONF'
*            iv_use_cache = abap_true.
*      CATCH cx_root INTO lx_root.
*        MESSAGE lx_root TYPE 'E'.
*    ENDTRY.
*    CREATE OBJECT lo_messaging TYPE /ui2/cl_fcm_messaging.
*    CREATE OBJECT lo_flp_cont_mgr TYPE /ui2/cl_flp_cont_mgr
*      EXPORTING
*        iv_scope       = 'CUST' "or 'CONF'
*        io_catalog_api = lo_catalog_api
*        io_messaging   = lo_messaging.
*    r_result = lo_flp_cont_mgr-&amp;gt;get_all_tiles_tms( ).
  ENDMETHOD.

  METHOD initialise_method.
    DATA writer TYPE REF TO if_siw_repository_writer.
    writer = cl_siw_resource_access=&amp;gt;s_get_instance( ).
    DATA source_code TYPE siw_tab_code.
    TRY.
        writer-&amp;gt;read_method_source(
                  EXPORTING
                    i_clsname    = 'ZCL_DYNAMIC_METHOD_CHANGE_DEMO'
                    i_methodname = 'GET_ALL_TILES_TMS'
                    i_state      = 'I'
                   IMPORTING
                     e_tab_code = source_code ).
        source_code = strip_out_comments( source_code ).
        writer-&amp;gt;write_class_method(
            i_clsname     = 'ZCL_DYNAMIC_METHOD_CHANGE_DEMO'
            i_methodname  = 'GET_ALL_TILES_TMS'
            i_tab_code    = source_code ).
        DATA rf_error TYPE REF TO cx_siw_resource_failure..
      CATCH cx_siw_resource_failure.
        MESSAGE rf_error TYPE 'E'.
    ENDTRY.
  ENDMETHOD.

  METHOD method_not_initialised.
    DATA writer TYPE REF TO if_siw_repository_writer.
    writer = cl_siw_resource_access=&amp;gt;s_get_instance( ).
    DATA source_code TYPE siw_tab_code.
    TRY.
        writer-&amp;gt;read_method_source(
                  EXPORTING
                    i_clsname    = 'ZCL_DYNAMIC_METHOD_CHANGE_DEMO'
                    i_methodname = 'GET_ALL_TILES_TMS'
                    i_state      = 'I'
                   IMPORTING
                     e_tab_code = source_code ).
        DATA rf_error TYPE REF TO cx_siw_resource_failure.
      CATCH cx_siw_resource_failure INTO rf_error.
        MESSAGE rf_error TYPE 'E'.
    ENDTRY.
    r_result = abap_false.
    FIELD-SYMBOLS &amp;lt;source_code_line&amp;gt; TYPE siw_dte_code.
    LOOP AT source_code ASSIGNING &amp;lt;source_code_line&amp;gt;.
      CHECK sy-tabix NE 1 AND sy-tabix NE lines( source_code )
                          AND ( &amp;lt;source_code_line&amp;gt; IS INITIAL 
                            OR &amp;lt;source_code_line&amp;gt;(1) NE '*' ).
      r_result = abap_true.
      EXIT.
    ENDLOOP.
  ENDMETHOD.

  METHOD strip_out_comments.
    r_result = i_source_code.
    FIELD-SYMBOLS &amp;lt;source_code_line&amp;gt; TYPE siw_dte_code.
    LOOP AT r_result ASSIGNING &amp;lt;source_code_line&amp;gt;.
      CHECK sy-tabix NE 1 AND sy-tabix NE lines( r_result ) 
                          AND &amp;lt;source_code_line&amp;gt; IS NOT INITIAL
                          AND &amp;lt;source_code_line&amp;gt;(1) EQ '*'.
      &amp;lt;source_code_line&amp;gt; = &amp;lt;source_code_line&amp;gt;+1.
    ENDLOOP.
  ENDMETHOD.
ENDCLASS.
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 30 Dec 2019 11:41:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/dynamic-create-object-with-parameters-ref-to-interface/m-p/12066036#M1969672</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2019-12-30T11:41:17Z</dc:date>
    </item>
  </channel>
</rss>

