<?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: Problem in BADI, error message not getting displayed in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573004#M587697</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Radhika,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Which BADI are you using for validating your PR? Anyway, I believe you can use ME_PROCESS_REQ_CUST~PROCESS_ITEM In here, you can trigger messages.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But you must have the include:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;INCLUDE mm_messages_mac.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then to call your message you can use this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;      mmpur_message_forced &amp;lt;Message type&amp;gt;
                    &amp;lt;Message ID&amp;gt;
                    &amp;lt;Message No&amp;gt;
                    &amp;lt;sy-msgv1&amp;gt;
                    &amp;lt;sy-msgv2&amp;gt;
                    &amp;lt;sy-msgv3&amp;gt;
                    &amp;lt;sy-msgv4&amp;gt;.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 26 Jul 2007 11:09:52 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-07-26T11:09:52Z</dc:date>
    <item>
      <title>Problem in BADI, error message not getting displayed</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573001#M587694</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Experts,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am facing a strange problem in BADI. &lt;/P&gt;&lt;P&gt;The requirement is that the user should not be allowed to change the plant field&lt;/P&gt;&lt;P&gt;on the screen of standard MM transctions for PO/PR amendment.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have written the code in separate BADIs for PO and PR.&lt;/P&gt;&lt;P&gt;I am displaying an error message if the user tries to change the field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For PO, it is working fine.But for PR, the same code is not working.&lt;/P&gt;&lt;P&gt;The control is going over to the BADI for PR and rest of the code is working fine.&lt;/P&gt;&lt;P&gt;But the error message is not getting displayed for PR amendment.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody please suggest the possible cause of problem and some solution to it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Jul 2007 06:35:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573001#M587694</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-26T06:35:38Z</dc:date>
    </item>
    <item>
      <title>Re: Problem in BADI, error message not getting displayed</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573002#M587695</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;     In BADI u cannt raise Error Messages but u can Post the Messages to Application Logs, So u have to Update ur messages to CT_LOG.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Jul 2007 06:47:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573002#M587695</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-26T06:47:33Z</dc:date>
    </item>
    <item>
      <title>Re: Problem in BADI, error message not getting displayed</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573003#M587696</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;See the sample BADI code for PR which raises an exceptions and do accordingly&lt;/P&gt;&lt;P&gt;BAdI Name: ZPUR_RFQ (Implementation name) Purchase Requisitions&lt;/P&gt;&lt;P&gt;Definition Name: ME_REQ_POSTED&lt;/P&gt;&lt;P&gt;Interface Name : IF_EX_ME_REQ_POSTED&lt;/P&gt;&lt;P&gt;Implementing Class: ZCL_IM_PUR_REQ&lt;/P&gt;&lt;P&gt;Method :            POSTED&lt;/P&gt;&lt;P&gt;************************************************************************&lt;/P&gt;&lt;P&gt;METHOD if_ex_me_req_posted~posted .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  DATA : v_mtart TYPE mtart.&lt;/P&gt;&lt;P&gt;  DATA l_s_eban TYPE ueban.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  LOOP AT im_eban INTO l_s_eban.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    IF l_s_eban-estkz NE 'B'.&lt;/P&gt;&lt;P&gt;      CLEAR v_mtart.&lt;/P&gt;&lt;P&gt;      SELECT SINGLE  mtart INTO v_mtart FROM mara WHERE matnr = l_s_eban-matnr.&lt;/P&gt;&lt;P&gt;      IF v_mtart EQ 'ZERS' OR v_mtart EQ 'FHMI' OR v_mtart EQ 'UNBW'.&lt;/P&gt;&lt;P&gt;        MESSAGE e000(zm_msg) WITH 'You are not allowed' 'to create PR for stock items'.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    IF  l_s_eban-knttp NE 'F' OR l_s_eban-pstyp NE '9'.&lt;/P&gt;&lt;P&gt;      IF l_s_eban-knttp NE 'A'.&lt;/P&gt;&lt;P&gt;        IF ( l_s_eban-pstyp NE '9' AND l_s_eban-pstyp NE 'D' )  &lt;/P&gt;&lt;P&gt;           AND l_s_eban-matnr EQ space.&lt;/P&gt;&lt;P&gt;          MESSAGE e000(zm_msg) WITH 'You cannot create' &lt;/P&gt;&lt;P&gt;            'a PR without material number'.&lt;/P&gt;&lt;P&gt;        ENDIF.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;  ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDMETHOD.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Reward points for useful Answers&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Anji&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Jul 2007 06:47:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573003#M587696</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-26T06:47:35Z</dc:date>
    </item>
    <item>
      <title>Re: Problem in BADI, error message not getting displayed</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573004#M587697</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Radhika,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Which BADI are you using for validating your PR? Anyway, I believe you can use ME_PROCESS_REQ_CUST~PROCESS_ITEM In here, you can trigger messages.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But you must have the include:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;INCLUDE mm_messages_mac.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then to call your message you can use this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;      mmpur_message_forced &amp;lt;Message type&amp;gt;
                    &amp;lt;Message ID&amp;gt;
                    &amp;lt;Message No&amp;gt;
                    &amp;lt;sy-msgv1&amp;gt;
                    &amp;lt;sy-msgv2&amp;gt;
                    &amp;lt;sy-msgv3&amp;gt;
                    &amp;lt;sy-msgv4&amp;gt;.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Jul 2007 11:09:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-in-badi-error-message-not-getting-displayed/m-p/2573004#M587697</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-26T11:09:52Z</dc:date>
    </item>
  </channel>
</rss>

