<?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 Call to external subroutines from include program in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317830#M508519</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have an include program and i need to call an external subroutine from inside this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; PERFORM Ztest in program ( ztestvalid ) if exists. -- in include program&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;created external subroutine pool program-ztestvalid&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM Ztest&lt;/P&gt;&lt;P&gt;endform.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But the program fails at perform &lt;/P&gt;&lt;P&gt;Can any one please let me know how i can call an external subroutine from a program.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 19 May 2007 16:16:32 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-05-19T16:16:32Z</dc:date>
    <item>
      <title>Call to external subroutines from include program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317830#M508519</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have an include program and i need to call an external subroutine from inside this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; PERFORM Ztest in program ( ztestvalid ) if exists. -- in include program&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;created external subroutine pool program-ztestvalid&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM Ztest&lt;/P&gt;&lt;P&gt;endform.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But the program fails at perform &lt;/P&gt;&lt;P&gt;Can any one please let me know how i can call an external subroutine from a program.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 19 May 2007 16:16:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317830#M508519</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-19T16:16:32Z</dc:date>
    </item>
    <item>
      <title>Re: Call to external subroutines from include program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317831#M508520</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Narendra&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Perhaps you have a problem with upper/lower case of the program names. Here is an example that works.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*&amp;amp; Subroutine pool   ZUS_SDN_SUBROUTINE_POOL&lt;/P&gt;&lt;P&gt;*&amp;amp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*&amp;amp;&lt;/P&gt;&lt;P&gt;*&amp;amp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;PROGRAM  ZUS_SDN_SUBROUTINE_POOL.
" This is my (external) subroutine pool

*&amp;amp;---------------------------------------------------------------------*
*&amp;amp;      Form  MY_ROUTINE
*&amp;amp;---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*  --&amp;gt;  p1        text
*  &amp;lt;--  p2        text
*----------------------------------------------------------------------*
form MY_ROUTINE .

  message 'My routine called externally' type 'I'.

endform.                    " MY_ROUTINE&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And here is the report using an external routine:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Report  ZUS_SDN_PERFORM_EXTERNAL
*&amp;amp;
*&amp;amp;---------------------------------------------------------------------*
*&amp;amp;
*&amp;amp;
*&amp;amp;---------------------------------------------------------------------*

REPORT  zus_sdn_perform_external.


DATA:
  gd_report    TYPE progname.


START-OF-SELECTION.


  PERFORM unknown_routine IN PROGRAM ('ZUS_SDN_SUBROUTINE_POOL')
                          IF FOUND.

  PERFORM my_routine IN PROGRAM ('ZUS_SDN_SUBROUTINE_POOL')
                     IF FOUND.
*
  gd_report = 'ZUS_SDN_SUBROUTINE_POOL'.  " upper case !!!
  PERFORM my_routine IN PROGRAM (gd_report)
                     IF FOUND.


END-OF-SELECTION.&lt;/CODE&gt;&lt;/PRE&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>Sat, 19 May 2007 19:51:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317831#M508520</guid>
      <dc:creator>uwe_schieferstein</dc:creator>
      <dc:date>2007-05-19T19:51:39Z</dc:date>
    </item>
    <item>
      <title>Re: Call to external subroutines from include program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317832#M508521</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Narendra,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Specify the Subroutine name as well as the program name in Capital letters. If this doesn't help please post the error message so that we may be able to help you better.&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>Sun, 20 May 2007 04:28:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317832#M508521</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-20T04:28:10Z</dc:date>
    </item>
    <item>
      <title>Re: Call to external subroutines from include program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317833#M508522</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use always upper case and you will get better results..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PERFORM Ztest in program ( 'ZTESTVALID' ) if exists. -- in include program&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;created external subroutine pool program-ztestvalid&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM Ztest&lt;/P&gt;&lt;P&gt;endform.&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;Seshu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 20 May 2007 04:32:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317833#M508522</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-05-20T04:32:47Z</dc:date>
    </item>
    <item>
      <title>Re: Call to external subroutines from include program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317834#M508523</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;done&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Apr 2008 19:27:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/call-to-external-subroutines-from-include-program/m-p/2317834#M508523</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-30T19:27:52Z</dc:date>
    </item>
  </channel>
</rss>

