<?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: Calling an FM in Background Task in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504974#M1558889</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;Are you using a "starting new task" approach??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If this is the case, have you tried the addition "PERFORMING ..... ON END OF TASK"??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You most declare a routine as follows&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
form process_results.
......
.....

RECEIVE RESULTS FROM 'FUNCTION_MODULE'.

.....
....

endform.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Doing this, your calls to the FUNCTION_MODULE may look like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
Call function 'FUNCTION_MODULE' starting new task g_taskname
destination in group g_group
performing process_results on end of task
.....
....
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;With this you can process the return table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this may help you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 29 Nov 2010 16:46:22 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2010-11-29T16:46:22Z</dc:date>
    <item>
      <title>Calling an FM in Background Task</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504971#M1558886</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Experts,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am calling an RFC Function module in Background Task. I need to capture the return table of this FM. Since i call in background task am unable to capture the return table. Can you provide any other appropriate solution where i can make use of the return table paramters from the FM?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pls Help.&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;Ramanan RS&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Nov 2010 11:37:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504971#M1558886</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-29T11:37:43Z</dc:date>
    </item>
    <item>
      <title>Re: Calling an FM in Background Task</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504972#M1558887</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can save records into a DB table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Nov 2010 13:03:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504972#M1558887</guid>
      <dc:creator>LucianoBentiveg</dc:creator>
      <dc:date>2010-11-29T13:03:43Z</dc:date>
    </item>
    <item>
      <title>Re: Calling an FM in Background Task</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504973#M1558888</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Create  A DB  dtab table with table with components of the return table of the function module.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After the function module completes successfully.&lt;/P&gt;&lt;P&gt;Add code to &lt;/P&gt;&lt;P&gt;Loop after the return table of the FUN module&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;itab--&amp;gt; internal table&lt;/P&gt;&lt;P&gt;istr line of itab&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab into istruc&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;append istruc to dtab.&lt;/P&gt;&lt;P&gt;if sy-subrc &amp;lt;&amp;gt;0&lt;/P&gt;&lt;P&gt;error.&lt;/P&gt;&lt;P&gt;ENDLOOP&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Vighneswaran CE on Nov 29, 2010 2:23 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Nov 2010 13:19:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504973#M1558888</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-29T13:19:55Z</dc:date>
    </item>
    <item>
      <title>Re: Calling an FM in Background Task</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504974#M1558889</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;Are you using a "starting new task" approach??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If this is the case, have you tried the addition "PERFORMING ..... ON END OF TASK"??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You most declare a routine as follows&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
form process_results.
......
.....

RECEIVE RESULTS FROM 'FUNCTION_MODULE'.

.....
....

endform.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Doing this, your calls to the FUNCTION_MODULE may look like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
Call function 'FUNCTION_MODULE' starting new task g_taskname
destination in group g_group
performing process_results on end of task
.....
....
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;With this you can process the return table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this may help you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Nov 2010 16:46:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-an-fm-in-background-task/m-p/7504974#M1558889</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-11-29T16:46:22Z</dc:date>
    </item>
  </channel>
</rss>

