<?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 BAPI_SALESORDER_CHANGE in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-salesorder-change/m-p/2117013#M443238</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I need to implement bapi_salesorder_change &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;if actioncode = 'aa' update delivery block to blank and customergroup2 to aa 
if actioncode = 'ac' update delivery block to blank and customergroup2 to ac ....&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I dont know how to implement bapi change. I have been told  I can either flag fields or compare fields. But I do not know how to write code to implement any of this. Could someone help me please.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 11 Apr 2007 13:56:14 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-04-11T13:56:14Z</dc:date>
    <item>
      <title>BAPI_SALESORDER_CHANGE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-salesorder-change/m-p/2117013#M443238</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I need to implement bapi_salesorder_change &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;if actioncode = 'aa' update delivery block to blank and customergroup2 to aa 
if actioncode = 'ac' update delivery block to blank and customergroup2 to ac ....&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I dont know how to implement bapi change. I have been told  I can either flag fields or compare fields. But I do not know how to write code to implement any of this. Could someone help me please.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Apr 2007 13:56:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-salesorder-change/m-p/2117013#M443238</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-11T13:56:14Z</dc:date>
    </item>
    <item>
      <title>Re: BAPI_SALESORDER_CHANGE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-salesorder-change/m-p/2117014#M443239</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;You need to populate the field DLV_BLOCK and CUST_GROUP in ORDER_HEADER_IN and ORDER_HEADER_INX parameters.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please try somethng like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
 DATA: LS_HEAD     TYPE BAPISDH1,
       LS_HEAD_X   TYPE BAPISDH1X,
       LT_MESSAGES LIKE BAPIRET2 OCCURS 5 WITH HEADER LINE.

 IF ACTIONCODE = 'AA'.
   MOVE SPACE TO LS_HEAD-DLV_BLOCK.
   MOVE 'AA'  TO LS_HEAD-CUST_GROUP.
   MOVE 'X'   TO LS_HEADX-DLV_BLOCK.
   MOVE 'X'   TO LS_HEADX-CUST_GROUP.
   MOVE 'U'   TO LS_HEADX-UPDATEFLAG.
 ELSEIF ACTIONCODE = 'AC'.
   MOVE SPACE TO LS_HEAD-DLV_BLOCK.
   MOVE 'AC'  TO LS_HEAD-CUST_GROUP.
   MOVE 'X'   TO LS_HEADX-DLV_BLOCK.
   MOVE 'X'   TO LS_HEADX-CUST_GROUP.
   MOVE 'U'   TO LS_HEADX-UPDATEFLAG.
 ELSE.
   ...
 ENDIF. 

 CALL FUNCTION 'BAPI_SALESORDER_CHANGE'
   EXPORTING
     SALESDOCUMENT       = LV_VBELN
     ORDER_HEADER_IN     = LS_HEAD
     ORDER_HEADER_INX    = LS_HEAD_X
   TABLES
     RETURN              = LT_MESSAGES.
 
  ...
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also please check this link for more sample codes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://sap4.com/wiki/index.php?title=BAPI_SALESORDER_CHANGE" target="test_blank"&gt;http://sap4.com/wiki/index.php?title=BAPI_SALESORDER_CHANGE&lt;/A&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;Ferry Lianto&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Apr 2007 14:23:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/bapi-salesorder-change/m-p/2117014#M443239</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-11T14:23:19Z</dc:date>
    </item>
  </channel>
</rss>

