<?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: MB1A User Exit at document save in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895101#M1480556</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you kindly for your post, unfortunately I could see that only A and X messages are allowed in that BADI, the request is specific to display only a warning message (so MB_DOCUMENT_BEFORE_UPDATE is not useful - this is why I reopened this thread).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The question is what to use instead, so I get access to all document lines and be able to show the warning message (like in the business flow described at the top of this thread).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 17 May 2010 11:11:48 GMT</pubDate>
    <dc:creator>former_member360630</dc:creator>
    <dc:date>2010-05-17T11:11:48Z</dc:date>
    <item>
      <title>MB1A User Exit at document save</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895097#M1480552</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a requirement related to MB1A for materials distribution to personnel defined in HR. This can happen at line &amp;lt;Enter&amp;gt; press or at 'Document Save' time (either one is good, but could not get any to work). The requirements are:&lt;/P&gt;&lt;P&gt;- get all material quantities in all the lines of the document&lt;/P&gt;&lt;P&gt;- match the materials against a custom price table and get the total amount of the document&lt;/P&gt;&lt;P&gt;- compair the total amount with some value related to the person HR that receives the materials&lt;/P&gt;&lt;P&gt;- send a message to the user if the total amount is greater than the value&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For this I tried MBCF0002 but here only get access to the current line item, not to all of them so I cannot get the total amount, only the line amount. I am aware about some other user exits but in none of them I could get a hold of all line items in the document before the document would be saved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you know if there is a user exit where as parameters there are available all line items, or where can I find them, if I use MBCF0002?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 May 2010 07:32:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895097#M1480552</guid>
      <dc:creator>former_member360630</dc:creator>
      <dc:date>2010-05-13T07:32:11Z</dc:date>
    </item>
    <item>
      <title>Re: MB1A User Exit at document save</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895098#M1480553</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check the methods "MB_DOCUMENT_BEFORE_UPDATE" &amp;amp; "MB_DOCUMENT_UPDATE" in badi implementation of "MB_DOCUMENT_BADI".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Vinod&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 May 2010 07:37:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895098#M1480553</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-05-13T07:37:54Z</dc:date>
    </item>
    <item>
      <title>Re: MB1A User Exit at document save</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895099#M1480554</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Used MB_DOCUMENT_BADI but get an error using the described business logic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The implementation text for MB_DOCUMENT_BEFORE_UPDATE method is:&lt;/P&gt;&lt;P&gt;______________&lt;/P&gt;&lt;P&gt;(... some select from ztable and call for HR infotype, no insert or update...)&lt;/P&gt;&lt;P&gt;MESSAGE 'display text here' TYPE 'W'.&lt;/P&gt;&lt;P&gt;______________&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is that user will see the message then try to modify the document lines. When trying this, he gets an ABAP error, message class M7, message number 372.&lt;/P&gt;&lt;P&gt;Checked the code in include MM07B9_BUCHEN_AUFBEREITEN in SAPMM07M program and found that this 'before_update' method is not supposed to be called more than once for some reason. In this case my business flow is broken (the request is to show the warning and then allow some modifications to the document, then check again).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you know of another user exit/badi that can help? For the workflow to function as requested, such a function should allow access to all document lines (not just a current line of the document line).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 May 2010 10:38:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895099#M1480554</guid>
      <dc:creator>former_member360630</dc:creator>
      <dc:date>2010-05-17T10:38:07Z</dc:date>
    </item>
    <item>
      <title>Re: MB1A User Exit at document save</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895100#M1480555</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Check these notes: 446057 and 1315985. MB_DOCUMENT_BEFORE_UPDATE  can issue only messages which type is X or A.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--&lt;/P&gt;&lt;P&gt;Reddy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 May 2010 10:56:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895100#M1480555</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-05-17T10:56:01Z</dc:date>
    </item>
    <item>
      <title>Re: MB1A User Exit at document save</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895101#M1480556</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you kindly for your post, unfortunately I could see that only A and X messages are allowed in that BADI, the request is specific to display only a warning message (so MB_DOCUMENT_BEFORE_UPDATE is not useful - this is why I reopened this thread).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The question is what to use instead, so I get access to all document lines and be able to show the warning message (like in the business flow described at the top of this thread).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 May 2010 11:11:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/mb1a-user-exit-at-document-save/m-p/6895101#M1480556</guid>
      <dc:creator>former_member360630</dc:creator>
      <dc:date>2010-05-17T11:11:48Z</dc:date>
    </item>
  </channel>
</rss>

