<?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: passing table to subroutine in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206866#M1626948</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Then define lt_ekbe globally.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 19 Oct 2011 15:56:37 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2011-10-19T15:56:37Z</dc:date>
    <item>
      <title>passing table to subroutine</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206862#M1626944</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a problem passing a table into a subroutine.&lt;/P&gt;&lt;P&gt;Here lt_ekbe is the internal Table as declared as follows.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;form Test. // The internal table lt_ekbe is declared in this subroutine.This subroutine Iam not allowed to change.
DATA: lt_ekbe  TYPE TABLE OF ekbe, 

Table is filled using the following routine.

PERFORM me_read_history TABLES lt_ekbe
                                 lt_ekbez
                          USING  ls_ekpo-ebeln
                                 ls_ekpo-ebelp.

end form.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the following routine, I want to pass the lt_ekbe table and make a check as follows.But it shows an error that table is not defined.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;form mwskz_from_rechnungsBeleg1 using ut_ekbe like lt_ekbe CHANGING fs TYPE mrer_item .
                               

data ls_ebke type ekbe.
READ TABLE ut_ebke into ls_ebke with key
                                   ebeln = fs-ebeln
				   BELNR = fs-rebzg
				   bwart = ''.

endform.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Could anyone give a hand on this..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;K&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Oct 2011 15:28:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206862#M1626944</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-10-19T15:28:55Z</dc:date>
    </item>
    <item>
      <title>Re: passing table to subroutine</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206863#M1626945</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I don't think you can do this without changing the first FORM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You could write a new FORM that does the same thing but passes the table. Pretty inefficient though.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why can't you change the FORM?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Oct 2011 15:36:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206863#M1626945</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-10-19T15:36:01Z</dc:date>
    </item>
    <item>
      <title>Re: passing table to subroutine</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206864#M1626946</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;But if you do know the specific type why don't you just use a table type such as &lt;STRONG&gt;ME_EKBE&lt;/STRONG&gt; or change the FORM structure using TABLES ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
form mwskz_from_rechnungsBeleg1 using ut_ekbe type ME_EKBE  CHANGING fs TYPE mrer_item .
....                               
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
form mwskz_from_rechnungsBeleg1 tables ut_ekbe structure ekbe  CHANGING fs TYPE mrer_item .
....                               
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Oct 2011 15:50:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206864#M1626946</guid>
      <dc:creator>former_member209703</dc:creator>
      <dc:date>2011-10-19T15:50:24Z</dc:date>
    </item>
    <item>
      <title>Re: passing table to subroutine</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206865#M1626947</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Rob,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I meant I want to call "mwskz_from_rechnungsBeleg1" from Test.No other changes other than that in subroutine "Test":)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Oct 2011 15:50:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206865#M1626947</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-10-19T15:50:26Z</dc:date>
    </item>
    <item>
      <title>Re: passing table to subroutine</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206866#M1626948</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Then define lt_ekbe globally.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 19 Oct 2011 15:56:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206866#M1626948</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-10-19T15:56:37Z</dc:date>
    </item>
    <item>
      <title>Re: passing table to subroutine</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206867#M1626949</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Jose,Rob...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 23 Oct 2011 13:27:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/passing-table-to-subroutine/m-p/8206867#M1626949</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-10-23T13:27:01Z</dc:date>
    </item>
  </channel>
</rss>

