<?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 difference between subroutine and function module in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526311#M572340</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;difference between subroutine and function module&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 12 Jul 2007 09:28:35 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-07-12T09:28:35Z</dc:date>
    <item>
      <title>difference between subroutine and function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526311#M572340</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;difference between subroutine and function module&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jul 2007 09:28:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526311#M572340</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-12T09:28:35Z</dc:date>
    </item>
    <item>
      <title>Re: difference between subroutine and function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526312#M572341</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;Here is the notes of differences bet. FM and Subroutines.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hi Function modules are for modularization urpose. You can the Function Module in any program. That is available all over in the SAP system.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Where as subroutine is program specific. Once you create a subroutine in one program then you can use that in that program and related programs like includes in the program or you have to call the subroutine specifically using the main program name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Finally subroutines are for program modularization. Not for generic use.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FM's are for generic use. Not program dependent.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FMs are mainly used when a routine is to be performed by many programs. &lt;/P&gt;&lt;P&gt;Subroutines (forms) are generally only executed within one program.&lt;/P&gt;&lt;P&gt;You can perform routines from other programs, but it's not often done.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;both forms and FMs are reusable modularization units. &lt;/P&gt;&lt;P&gt;To distinguish we generally say that forms are used for internal modularization and &lt;/P&gt;&lt;P&gt;FMs are used for external modularization.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To decide on which to implement, consider whether you need the content to be used just for a limited program&lt;/P&gt;&lt;P&gt;or wheteher it can be called from many independent programs. &lt;/P&gt;&lt;P&gt;For the first purpose it is better to implement a form whereas for the second we implement an FM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, ABAP does not isolate the usage context. &lt;/P&gt;&lt;P&gt;That is; you can call a form from another program within whose code the form is not actually implemented.&lt;/P&gt;&lt;P&gt;However, this requires attention since the form may utilize global variables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The same issue holds for FMs.&lt;/P&gt;&lt;P&gt;FMs are encapsulated in function groups and function groups may have global variables that can be globally &lt;/P&gt;&lt;P&gt;used by all FMs inside it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Priyanka.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jul 2007 09:30:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526312#M572341</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-12T09:30:45Z</dc:date>
    </item>
    <item>
      <title>Re: difference between subroutine and function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526313#M572342</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hai,&lt;/P&gt;&lt;P&gt;Check this link and reward if found helpfull,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_thread" href="https://community.sap.com/" __jive_macro_name="thread" modifiedtitle="true" __default_attr="401220"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;Rakesh.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jul 2007 09:31:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526313#M572342</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-12T09:31:39Z</dc:date>
    </item>
    <item>
      <title>Re: difference between subroutine and function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526314#M572343</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Subroutines are defined locally in the program and FMs are globally defined in SAP system.&lt;/P&gt;&lt;P&gt;You cant upload data or remotely access data using Subroutines, its possible in FM&lt;/P&gt;&lt;P&gt;Reward if useful!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jul 2007 09:31:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526314#M572343</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-12T09:31:47Z</dc:date>
    </item>
    <item>
      <title>Re: difference between subroutine and function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526315#M572344</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;Subroutines are program modules, which can be called from other ABAP/4 programs or within the same program. &lt;/P&gt;&lt;P&gt;types of subroutines:&lt;/P&gt;&lt;P&gt;     Internal Subroutines: The source code of the internal subroutines will be in the same ABAP/4 program as the calling procedure (internal call).&lt;/P&gt;&lt;P&gt;     External Subroutines: The source code of the external subroutines will be in an ABAP/4 program other than the calling procedure. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is  possible to create an ABAP/4 program, which contains only Subroutines &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                In contrast to normal subroutines function modules have uniquely defined interface.  Declaring data as common parts is not possible for function modules.  Function modules are stored in a central library&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;reward if useful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jul 2007 09:34:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526315#M572344</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-12T09:34:26Z</dc:date>
    </item>
    <item>
      <title>Re: difference between subroutine and function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526316#M572345</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;they can both return values. &lt;/P&gt;&lt;P&gt;FMs are mainly used when a routine is to be performed by many programs. &lt;/P&gt;&lt;P&gt;Subroutines (forms) are generally only executed within one program.&lt;/P&gt;&lt;P&gt; You can perform routines from other programs, but it's not often done.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;both forms and FMs are reusable modularization units. &lt;/P&gt;&lt;P&gt;To distinguish we generally say that forms are used for internal modularization and &lt;/P&gt;&lt;P&gt;FMs are used for external modularization.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To decide on which to implement, consider whether you need the content to be used just for a limited program&lt;/P&gt;&lt;P&gt; or wheteher it can be called from many independent programs. &lt;/P&gt;&lt;P&gt;For the first purpose it is better to implement a form whereas for the second we implement an FM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, ABAP does not isolate the usage context. &lt;/P&gt;&lt;P&gt;That is; you can call a form from another program within whose code the form is not actually implemented.&lt;/P&gt;&lt;P&gt; However, this requires attention since the form may utilize global variables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The same issue holds for FMs.&lt;/P&gt;&lt;P&gt; FMs are encapsulated in function groups and function groups may have global variables that can be globally &lt;/P&gt;&lt;P&gt;used by all FMs inside it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Reshma&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jul 2007 09:34:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526316#M572345</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-12T09:34:36Z</dc:date>
    </item>
    <item>
      <title>Re: difference between subroutine and function module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526317#M572346</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In contrast to normal subroutines function modules have uniquely defined interface.  Declaring data as common parts is not possible for function modules.  Function modules are stored in a central library. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Refer this link...&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sapbrainsonline.com/FAQs/TECHNICAL/SAP_ABAP_MODULARIZATION_FAQ.html" target="test_blank"&gt;http://www.sapbrainsonline.com/FAQs/TECHNICAL/SAP_ABAP_MODULARIZATION_FAQ.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Pavan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Jul 2007 09:37:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/difference-between-subroutine-and-function-module/m-p/2526317#M572346</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-12T09:37:01Z</dc:date>
    </item>
  </channel>
</rss>

