<?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: Message tracing from an Internal Table in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590146#M1082462</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;Put the foll code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;Loop at it_ret into wa_ret.

write: / wa_ret-message. " you can add more fields also If u want.

Endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Vishwa.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 06 Oct 2008 06:37:58 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-10-06T06:37:58Z</dc:date>
    <item>
      <title>Message tracing from an Internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590144#M1082460</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 using a BAPI which is giving me a &lt;STRONG&gt;return Internal table back loaded with the success, error and the warning messages&lt;/STRONG&gt;.  I would like to &lt;STRONG&gt;show those on my screen&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;Can anyone tell me how to do it?.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-=Soniya=-&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Oct 2008 06:33:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590144#M1082460</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-06T06:33:57Z</dc:date>
    </item>
    <item>
      <title>Re: Message tracing from an Internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590145#M1082461</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can simply write those msgs on screen after BAPI execution. &lt;/P&gt;&lt;P&gt;e.g. write &lt;span class="lia-unicode-emoji" title=":confused_face:"&gt;😕&lt;/span&gt; t_return-message.&lt;/P&gt;&lt;P&gt;Or &lt;/P&gt;&lt;P&gt;You can create ALV report.&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;Aparna&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Oct 2008 06:35:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590145#M1082461</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-06T06:35:48Z</dc:date>
    </item>
    <item>
      <title>Re: Message tracing from an Internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590146#M1082462</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;Put the foll code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;Loop at it_ret into wa_ret.

write: / wa_ret-message. " you can add more fields also If u want.

Endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Vishwa.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Oct 2008 06:37:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590146#M1082462</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-06T06:37:58Z</dc:date>
    </item>
    <item>
      <title>Re: Message tracing from an Internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590147#M1082463</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Soniya,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With this function, you can to get the message text.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CALL FUNCTION 'FORMAT_MESSAGE'
 EXPORTING
   ID              = MSGID
   LANG            = SY-LANGU
   NO              = MSGNO
   V1              = MSGV1
   V2              = MSGV2
   V3              = MSGV3
   V4              = MSGV4
 IMPORTING
   MSG             = V_MSG
 EXCEPTIONS
   NOT_FOUND       = 1
   OTHERS          = 2
          .
IF SY-SUBRC &amp;lt;&amp;gt; 0.
  MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here, V_MSG has a length of 200 &amp;amp; is a character type variable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;R.Nagarajan.&lt;/P&gt;&lt;P&gt;-&lt;/P&gt;&lt;HR originaltext="------" /&gt;&lt;P&gt; We can -&lt;/P&gt;&lt;HR originaltext="------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Oct 2008 06:42:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590147#M1082463</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-06T06:42:03Z</dc:date>
    </item>
    <item>
      <title>Re: Message tracing from an Internal Table</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590148#M1082464</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;We can show all mesages returned from BAPI in END-OF-SELECTION event.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Plz try this way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

*Internal table to hold messages from BAPI call
 DATA:  RETURN LIKE BAPIRET2 OCCURS 0 WITH HEADER LINE.

CALL FUNCTION 'BAPI_PO_CREATE1'
  EXPORTING
    POHEADER                     = HEADER
    POHEADERX                    = HEADERX
*   POADDRVENDOR                 =
*   TESTRUN                      =
* IMPORTING
*   EXPPURCHASEORDER             =
*   EXPHEADER                    =
*   EXPPOEXPIMPHEADER            =
 TABLES
   RETURN                       = RETURN
   POITEM                       = ITEM
   POITEMX                      = ITEMX.

*&amp;amp;---------------------------------------------------------------------*
*Confirm the document creation by calling database COMMIT
*&amp;amp;---------------------------------------------------------------------*
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
 EXPORTING
   WAIT          = 'X'
* IMPORTING
*   RETURN        =
          .

END-OF-SELECTION.
*&amp;amp;---------------------------------------------------------------------*
*Output the messages returned from BAPI call
*&amp;amp;---------------------------------------------------------------------*
LOOP AT RETURN.
 WRITE / RETURN-MESSAGE.
ENDLOOP.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this will write data to screen.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanx.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Dhanashri Pawar on Oct 6, 2008 8:46 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Oct 2008 06:45:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/message-tracing-from-an-internal-table/m-p/4590148#M1082464</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-10-06T06:45:10Z</dc:date>
    </item>
  </channel>
</rss>

