Change of ship-to party right before dispatch on delivery (not order)

have a client that consistently has to change the ship-to party right before dispatch. the client has customers that are dealers, who in turn have sub-dealers. the dealers very rarely accept shipment to their address, they want the delivery posted to the sub-dealers and this can change at the last minute. as of right now, the addresses for sub-dealers is not maintained by the client, but they would like to have this option.
i would like to maintain the address of the sub-dealers. but once the delivery document is created the ship-to party is greyed out, how would i change this, so i can enter a new ship-to party? the address changes last minute, but after the delivery has been created.
thanks in advance!

Hi
In standard SAP it is not possible.
Once , you create a Delivery document, you can not change the Ship-to-party. Ship-to-party is a Header data in Delivery.
If you want the change then you have to delete the Delivery.
Make your client understand that it is not only Ship-to-party, so many other  related data will get redetermine once the Ship-to-party is changed.
For example, When Ship-to-party is changed, Route will be redetermined, Tax will be redetermined, partial delivery agreement may be different etc.
The new Ship-to-party may have a choice of different Plant also.
Normally, the above data are determined in Sales order, therefore you can change those in Sales order only and NOT possible to change in the Delivery document.

Similar Messages

  • Change of ship-to party right before dispatch

    have a client that consistently has to change the ship-to party right before dispatch. the client has customers that are dealers, who in turn have sub-dealers. the dealers very rarely accept shipment to their address, they want the delivery posted to the sub-dealers and this can change at the last minute. as of right now, the addresses for sub-dealers is not maintained by the client, but they would like to have this option. so, a 2 part question, do we have to maintain the addresses for the sub-dealers or can we use them as a one-time customer? and 2, how would be change the ship-to address last minute right before dispatch?
    thanks a bunch!

    Hi Astro, 
    Option 1 - Since most of the Deliveries are shipped to the Sub Dealers, it is better to maintain Ship to Party Master Record for these Sub dealers and assign the same to the Sold to Party. Here, you have to justify the correct Ship to Party and maintain or change in Sales Order before the Delivery is created.
    Option 2 - Maintain one single Ship to Party for all the Sub Dealers and you can change the address of the Ship to party as required at the last minute before goods issue.
    Hope this will be helpful to u. let me know if anything.
    Rgds,
    Ravi.

  • BAPI_SALESORDER_CHANGE - Want to change the Ship-to-party at header level

    Hi
    I want to change the Ship-to-party at header level in the Sales Order created. I tried using the BAPI BAPI_SALESORDER_CHANGE  as shown below.
    When I run the program I get the log as Sales Order 45 saved succesfully. However, I don't find the SO changed. Apart from this I get an Express Message saying the Updation failure. Not sure of what'z wrong here.
    Pls help
    thanks
    girish
    REPORT  ZBAPI_SALESORD_CHANGE.
    data : zBAPISDHD       type BAPISDH1,
           zSALESDOCUMENT  type BAPIVBELN-VBELN.
    data : zORDER_ITEMS_IN     like /AFS/BAPISDITM occurs 0 with header line,
           zORDER_SCHEDULES_IN like /AFS/BAPISDSCHD occurs 0 with header line,
           zORDER_PARTNERS like BAPIPARNR      occurs 0 with header line,
           zRETURN         like BAPIRET2 occurs 0 with header line,
           so_no           type BAPIVBELN-VBELN,
           zORDER_HEADER_INX    TYPE BAPISDH1X,
           zPARTNERCHANGES like  BAPIPARNRC occurs 0 with header line.
    clear : zBAPISDHD.
    so_no = '0000000045'.
    data : l_comp_qty like zORDER_ITEMS_IN-COMP_QUANT.
    l_comp_qty = 10.
    zBAPISDHD-SALES_ORG = 'BP01'.
    zBAPISDHD-DISTR_CHAN = '02'.
    zBAPISDHD-DIVISION = '01'.
    zORDER_HEADER_INX-UPDATEFLAG = 'U'.
    zORDER_HEADER_INX-SALES_ORG  = 'X'.
    zORDER_HEADER_INX-DISTR_CHAN = 'X'.
    zORDER_HEADER_INX-DIVISION = 'X'.
    Ship to pary
    zORDER_PARTNERS-PARTN_ROLE = 'WE'.
    zORDER_PARTNERS-PARTN_NUMB = 'BPAFS0007'.
    append zORDER_PARTNERS.
    zPARTNERCHANGES-DOCUMENT = '45'.
    zPARTNERCHANGES-ITM_NUMBER = '10'.
    zPARTNERCHANGES-UPDATEFLAG = 'U'.
    zPARTNERCHANGES-PARTN_ROLE = 'WE'.
    zPARTNERCHANGES-P_NUMB_OLD = 'BPAFS0001'.
    zPARTNERCHANGES-P_NUMB_NEW = 'BPAFS0007'.
    append zPARTNERCHANGES.
    CALL FUNCTION 'BAPI_SALESORDER_CHANGE'
      EXPORTING
        SALESDOCUMENT               = so_no
        ORDER_HEADER_IN             = zBAPISDHD
        ORDER_HEADER_INX            = zORDER_HEADER_INX
      SIMULATION                  =
      BEHAVE_WHEN_ERROR           = ' '
      INT_NUMBER_ASSIGNMENT       = ' '
      LOGIC_SWITCH                =
      NO_STATUS_BUF_INIT          = ' '
      TABLES
        RETURN                      = zRETURN
      ORDER_ITEM_IN               =
      ORDER_ITEM_INX              =
        PARTNERS                    = zORDER_PARTNERS
        PARTNERCHANGES              = zPARTNERCHANGES.
      PARTNERADDRESSES            =
      ORDER_CFGS_REF              =
      ORDER_CFGS_INST             =
      ORDER_CFGS_PART_OF          =
      ORDER_CFGS_VALUE            =
      ORDER_CFGS_BLOB             =
      ORDER_CFGS_VK               =
      ORDER_CFGS_REFINST          =
      SCHEDULE_LINES              =
      SCHEDULE_LINESX             =
      ORDER_TEXT                  =
      ORDER_KEYS                  =
      CONDITIONS_IN               =
      CONDITIONS_INX              =
      EXTENSIONIN                 =
    data : s_BAPIRET2 like  BAPIRET2.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
    exporting
    wait = 'X'
    importing
    return = s_bapiret2.

    Thanks Prashanth. It worked !!!!!!!!!!!!!
    Now I am facing another type of problem. The requirement is to change the Sales Order Item Quantity. I basically planned to update the quantity of Schedule Item which needs to be changed. When I run the below code, it works and says the Sales Order changed succesfully. However I get an express message saying the Database update failure. I don't get any sort of technical information.
    Appreciate if you could help me finding the error.
    Thanks
    regards
    girish
    Note --> I am trying to change the Quantity for 2 line item in SO '56' to 40 Units.
    REPORT  ZBAPI_SALESORD_CHANGE.
    data : zBAPISDHD       type /AFS/BAPISDHD,
           zORDER_HEADER_INX    TYPE /AFS/BAPISDHDX,
           zSALESDOCUMENT  type BAPIVBELN-VBELN.
    data : zORDER_ITEMS_IN     like /AFS/BAPISDITM   occurs 0 with header line,
           zORDER_ITEM_INX     like /AFS/BAPISDITMX  occurs 0 with header line,
           zORDER_SCHEDULES_IN like /AFS/BAPISDSCHD  occurs 0 with header line,
           ZSCHEDULE_LINESX    LIKE /AFS/BAPISDSCHDX occurs 0 with header line,
           zORDER_PARTNERS like BAPIPARNR      occurs 0 with header line,
           zRETURN         like BAPIRET2 occurs 0 with header line,
           so_no           type BAPIVBELN-VBELN,
           zPARTNERCHANGES like  BAPIPARNRC occurs 0 with header line.
    data : l_comp_qty like zORDER_ITEMS_IN-COMP_QUANT.
    data : g_qty like /AFS/BAPISDSCHD-REQ_QTY.
    g_qty = 40.
    l_comp_qty = 40.
    clear : zBAPISDHD.
    so_no = '0000000056'.
    zBAPISDHD-REFOBJTYPE = '/AFS/ORDER'.
    zBAPISDHD-SALES_ORG = 'BP01'.
    zBAPISDHD-DISTR_CHAN = '02'.
    zBAPISDHD-DIVISION = '01'.
    zBAPISDHD-PMNTTRMS = '0001'.
    zORDER_HEADER_INX-UPDATEFLAG = 'U'.
    zORDER_HEADER_INX-SALES_ORG  = 'X'.
    zORDER_HEADER_INX-DISTR_CHAN = 'X'.
    zORDER_HEADER_INX-DIVISION = 'X'.
    zORDER_HEADER_INX-PMNTTRMS = 'X'.
    **********ITEM ***************************************
    zORDER_ITEMS_IN-ITM_NUMBER = '00020'.
    zORDER_ITEMS_IN-MATERIAL = 'F1202'.
    zORDER_ITEMS_IN-PLANT = 'BP01'.
    zORDER_ITEMS_IN-ITEM_CATEG = 'TAS'.
    zORDER_ITEMS_IN-SHIP_POINT = 'BP01'.
    zORDER_ITEMS_IN-COMP_QUANT = l_comp_qty.
    zORDER_ITEMS_IN-TARGET_QTY = l_comp_qty.
    zORDER_ITEMS_IN-TARGET_QU = 'ST'.
    append zORDER_ITEMS_IN.
    zORDER_ITEM_INX-ITM_NUMBER = '00020'.
    zORDER_ITEM_INX-UPDATEFLAG = 'U'.
    zORDER_ITEM_INX-MATERIAL = 'X'.
    zORDER_ITEM_INX-PLANT = 'X'.
    zORDER_ITEM_INX-ITEM_CATEG = 'X'.
    zORDER_ITEM_INX-SHIP_POINT = 'X'.
    zORDER_ITEM_INX-COMP_QUANT = 'X'.
    zORDER_ITEM_INX-TARGET_QTY = 'X'.
    zORDER_ITEM_INX-TARGET_QU = 'X'.
    append zORDER_ITEM_INX.
    *********SCHEDULE LINE******************************
    refresh zORDER_SCHEDULES_IN.
    clear zORDER_SCHEDULES_IN.
    zORDER_SCHEDULES_IN-ITM_NUMBER = '000020'.
    zORDER_SCHEDULES_IN-SCHED_LINE = '0001'.
    zORDER_SCHEDULES_IN-REQ_DATE = '20070525'.
    zORDER_SCHEDULES_IN-DATE_TYPE = '1'.
    zORDER_SCHEDULES_IN-SCHED_TYPE = 'CS'.
    zORDER_SCHEDULES_IN-GRID_VALUE = 'BLK2728'.
    zORDER_SCHEDULES_IN-REQ_CATEGORY = '1DE'.
    zORDER_SCHEDULES_IN-REFOBJTYPE = '/AFS/ORDER'.
    zORDER_SCHEDULES_IN-REQ_QTY = g_qty.
    append zORDER_SCHEDULES_IN.
    refresh ZSCHEDULE_LINESX.
    clear ZSCHEDULE_LINESX.
    ZSCHEDULE_LINESX-ITM_NUMBER = '000020'.
    ZSCHEDULE_LINESX-SCHED_LINE = '0001'.
    ZSCHEDULE_LINESX-UPDATEFLAG = 'U'.
    ZSCHEDULE_LINESX-REQ_DATE = 'X'.
    ZSCHEDULE_LINESX-DATE_TYPE = 'X'.
    ZSCHEDULE_LINESX-SCHED_TYPE = 'X'.
    ZSCHEDULE_LINESX-GRID_VALUE = 'X'.
    ZSCHEDULE_LINESX-REQ_CATEGORY = 'X'.
    ZSCHEDULE_LINESX-REFOBJTYPE = 'X'.
    ZSCHEDULE_LINESX-REQ_QTY = 'X'.
    append ZSCHEDULE_LINESX.
    CALL FUNCTION '/AFS/BAPI_SALESORD_CHANGE'
      EXPORTING
        SALESDOCUMENT               = so_no
        ORDER_HEADER_IN             = zBAPISDHD
        ORDER_HEADER_INX            = zORDER_HEADER_INX
      SIMULATION                  =
      BEHAVE_WHEN_ERROR           = ' '
      INT_NUMBER_ASSIGNMENT       = ' '
      LOGIC_SWITCH                =
      TABLES
        RETURN                      = zRETURN
        ORDER_ITEM_IN               = zORDER_ITEMS_IN
        ORDER_ITEM_INX              = zORDER_ITEM_INX
        ORDER_SCHEDULE_LINES        = zORDER_SCHEDULES_IN
        ORDER_SCHEDULE_LINESX       = ZSCHEDULE_LINESX.
      PARTNERS                    =
      PARTNERCHANGES              = zPARTNERCHANGES
      PARTNERADDRESSES            =
      ORDER_CFGS_REF              =
      ORDER_CFGS_INST             =
      ORDER_CFGS_PART_OF          =
      ORDER_CFGS_VALUE            =
      ORDER_CFGS_BLOB             =
      ORDER_CFGS_VK               =
      ORDER_CFGS_REFINST          =
      ORDER_TEXT                  =
      ORDER_KEYS                  =
      CONDITIONS_IN               =
      CONDITIONS_INX              =
      EXTENSIONIN                 =
    *CALL FUNCTION 'BAPI_SALESORDER_CHANGE'
    EXPORTING
       SALESDOCUMENT               = so_no
       ORDER_HEADER_IN             = zBAPISDHD
       ORDER_HEADER_INX            = zORDER_HEADER_INX
    TABLES
       RETURN                      = zRETURN
       ORDER_ITEM_IN               = zORDER_ITEMS_IN
       ORDER_ITEM_INX              = zORDER_ITEM_INX
       PARTNERS                    = zORDER_PARTNERS
       PARTNERCHANGES              = zPARTNERCHANGES
      PARTNERADDRESSES            =
      ORDER_CFGS_REF              =
      ORDER_CFGS_INST             =
      ORDER_CFGS_PART_OF          =
      ORDER_CFGS_VALUE            =
      ORDER_CFGS_BLOB             =
      ORDER_CFGS_VK               =
      ORDER_CFGS_REFINST          =
      SCHEDULE_LINES               = zORDER_SCHEDULES_IN
      SCHEDULE_LINESX              = ZSCHEDULE_LINESX.
      ORDER_TEXT                  =
      ORDER_KEYS                  =
      CONDITIONS_IN               =
      CONDITIONS_INX              =
      EXTENSIONIN                 =
    data : s_BAPIRET2 like  BAPIRET2.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
    importing
    return = s_bapiret2.

  • Any exits to change the ship-to-party in VA01 before its display

    Hi All,
    I'm having a situation here that i would need your help.
    From IW51 i'll create a sales order VA01 and just before creation i would need to do some validation on the plant and service center and then change the Ship-to-party value to another.
    I am not sure on which exit or badi offers that functions. the ones that i've found is EXIT_SAPLV46H_002 and EXIT_SAPLV09A_004. Both of this doesn't work.
    If any one of you has encountered this problem and manage to resolve it please help me resolve mine as well.
    Thank you.
    Vinod

    Hi,
    here u will find complete example:
    http://sap.niraj.tripod.com/id21.html
    Jogdand M B

  • User Exit to change the Ship-to party address at Sales Order headder level

    Hi,
    I have requirement like this......
    I need to change the  ship-to party address at Sales Order headder level. for that which user exit i need to  use and which structure i need to use to update the transaction.
    I used : userexit_save_document_prepare, in that i passed data to 'xvbpa' and 'xvbadr' structures. even though it is not update the transaction.
    Please let me know the answer.
    Thanks,
    Satish.

    Hi Satish,
    Step1. Create new Data Copy Routine using Tcode VOFM.
    Step2. *-----------------------------------Ship to Party from contract
       IF CVBPA-PARVW = 'WE' OR
          CVBPA-PARVW = 'SH'.
        REFRESH IT_STP.
        SELECT KTOKD
               A~KUNNR
               NAME1
               NAME2
               A~ADRNR
               FROM VBPA AS A INNER JOIN KNA1 AS B ON A~KUNNR = B~KUNNR
               INTO CORRESPONDING FIELDS OF TABLE IT_STP
               WHERE VBELN = CVBPA-VBELN . 
    Step3.
       CALL FUNCTION 'POPUP_WITH_TABLE_DISPLAY'
            EXPORTING
              ENDPOS_COL   = 80
              ENDPOS_ROW   = 10
              STARTPOS_COL = 10
              STARTPOS_ROW = 5
              TITLETEXT    = 'Your Title'
            IMPORTING
              CHOISE       = T_SELIDX<=====Index No of selection
            TABLES
              VALUETAB     = IT_STP
            EXCEPTIONS
              BREAK_OFF    = 1
              OTHERS       = 2.
    Step4.
           READ TABLE IT_STP INTO WA_STP INDEX T_SELIDX.
            IF SY-SUBRC = 0.
              CLEAR:CVBPA-KUNNR, CVBPA-ADRNR.
              MOVE WA_STP-KUNNR TO CVBPA-KUNNR.
              MOVE WA_STP-ADRNR TO CVBPA-ADRNR. <========Address ID (Change Here).  
           ENDIF.
    Regards,
    Amrendra
    Moderator Message - Please do not reply to old, dormant threads.
    Message was edited by: Suhas Saha

  • Change of Ship-to-party address in IC WebClient

    Dear Guru's,
    Acc. my business requirement i need to configure IC-webclient,
    Scenario1:- End User should be able to change the Ship-to-party address (on customers request) thru IC-Webclient. (in this scenario sold-to-party & ship-to-party are 2 different addresses.)
    can ny1 guide me on this.
    Thanx in advance
    -Nirav.

    Hi,
    Nirav
    Pull in the Transaction BP view from the transaction launcher .This will have the BP transaction which will have the details in edit mode for you .You can restrict the views with authorisations for the user.
    Hope this will resolve your Issue
    Regards
    Raj
    Don't forget to reward!!

  • No text redetermination once change the ship to party

    Hello Experts,
    We have text like picking/packing/shipping text in ship to party. and we have assigned such text value in ship to party.
    Suppose:
    Ship to party A has shipping text: ABCDEFG
    Ship to party B has shipping text: 12345678
    I create the sales order with ship to party: A and system determine text (header level) as ABCDEFG, I save it later i change the ship to party in sale order from A to B. according to business logic system should change the shipping text from ABCDEFG to 12345678 once I change the ship to party from A to B. But it is not happening.
    Even though changing the ship to party from A to B, system is not redetermining text and I am wondering why it's happening?
    Is it the standard functionality ? why it is happening ?
    Thanks,

    How text will be redetermined if the ship to party is changed
    Please refer the above tread, System does not re determine the text if Ship to party  is changed, it changes only for SP, also if you want to redetermine the SH text then refer the notes also which was mentioned in the above tread.
    thanks,
    Srinu.

  • Change in Ship To Party

    How to change the ship to party when PO raised and sent to vendor in the 3rd party sales?
    Edited by: Lakshmipathi on Aug 28, 2011 8:05 AM
    Please use the subject effectively

    Hi gaddammai ,
    u can change Ship to Party goto va02 tcode then Goto -> Header -> Partner...
    but u should have shipping point determination in place
    u can change any partner at sales order level only Sold to Party remains unchanged in standard sap System.
    Thanks & Regards,
    Deepaks

  • Delivery not before date and Delivery not after date

    Hi Everyone,
    Can anyone help me in this issue, we need to map "delivery not before date" and "delivery not after date" from an EDI 850 into a sales order.
    Are there any fields to which we can map the data? if not would anyone suggest how to go about it?
    Thanks,
    Michelle.

    Michelle,
    We have a similar requirement, albeit we call it a Delivery Window. We have implemented this by mapping two E1EDK03 qualifiers (we use 033 & 034) to two Z fields extended to VBAK, which we then include in our Sales Order Delivery Date logic.
    Not very elegant, but then my understanding is that SAP has no concept of the Delivery Window.
    Cheers, Paul.

  • Exit for changing Pricing Conditions with change in Ship to party

    Hi All,
    In transaction VA01/ VA02 the pricing conditions are getting calculated with respect to the Sold-to-party no.. Instead I wanted it to get calculated with respect to the Ship-to-party. Please guide me with an Exit that i can use, or any other way of solving this.
    Thanks in Advance.

    Hi Roberto,
    I am creating a sales order with transaction VA01 using a  Sold-to-party say 1 and a Ship-to-party 2. While saving the order the tax calculations (if it is interstate - cst and intrastate - vat) are happening with respect to the Sold-to-party.
    But I want it to happen with respect to the Ship-to-party. Is there anyway of changing this tax calculations in the pricing condition to take place with respect to my Ship-to-party.

  • Change of Ship to Party on sales order after invoice

    Hi all,
    I have created a sales order, created a despatch advice and then created an invoice. After that i opened sales order and changed ship to party there. System is allowing me to change ship to party on sales order after invoice. I want that system should not let me change ship to party on sales order after invoice.
    How can i do that as this is an audit issue as we have different prices for different ship to parties.
    Please respond.
    Best Regards,
    AI.

    Hi
    You have two options
    1. create a transaction variant in T.code SHD0 for VA02 and make the field as display in the variant. But remember that you will not be able to use standard T.code VA02 after this, you need to make and use a "Z" t.code like ZA02
    2. Take the help of your ABAPER and ask him to find a screen exit in the sales order PBO module, where he will be able to grey out the ship to party field.
    Hope this helps
    Chandra Kiran

  • BAPI_SALESORDER_CREATEFROMDAT2 not changing customer ship-to-party city and address

    Hi all,
    When we are creating sales order from VA01 we can change ship-to-party CITY1 and REGION from partners in the header information. I show it in the picture below;
    I create orders with BAPI_SALESORDER_CREATEFROMDAT2 but i cant change the CITY and REGION. PLEASE give me some information about how can i do that. My code is at the end. THANKS VERY MUCH TO ALL.
    data: v_vbeln       like vbak-vbeln,
        header_in     like BAPISDHD1,
        header_inx    like BAPISDHD1X,
        items_in      like BAPISDITM    occurs 0 with header line,
        items_inx     like BAPISDITMX   occurs 0 with header line,
        partners      like BAPIPARNR    occurs 0 with header line,
        schedules_in  like BAPISCHDL    occurs 0 with header line,
        schedules_inx like BAPISCHDLX   occurs 0 with header line,
        return        like BAPIRET2     occurs 0 with header line,
        partner_address like BAPIADDR1  occurs 0 with header line.
    data: lv_adrnr type kna1-adrnr.
        header_in-doc_type   = ls_data-auart.
        header_in-sales_org  = ls_data-vkorg.
        header_in-distr_chan = ls_data-vtweg.
        header_in-division   = ls_data-spart.
        header_in-PMNTTRMS   = ls_data-zterm.
        header_in-PURCH_DATE = ls_data-girdat.
        header_inx-doc_type   = 'X'.
        header_inx-sales_org  = 'X'.
        header_inx-distr_chan = 'X'.
        header_inx-division   = 'X'.
        header_inx-updateflag = 'I'.
        header_inx-PMNTTRMS   = 'X'.
        items_in-itm_number   = ls_data-posnr.
        items_in-material     = ls_data-matnr.
        items_in-plant        = '2110'.
        items_in-target_qty   = ls_data-kwmeng.
        items_in-target_qu   = ls_data-vrkme.
    *    items_in-ITEM_CATEG   = PSTYV.
        append items_in.
        items_inx-itm_number   = 'X'.
        items_inx-material     = 'X'.
        items_inx-plant        = 'X'.
        items_inx-target_qty   = 'X'.
        items_inx-target_qu    = 'X'.
    *    items_in-ITEM_CATEG   = 'X'.
        append items_inx.
        partners-partn_role    = 'AG'. 
        partners-partn_numb    = ls_data-kunnr.
        append partners.
        partners-partn_role    = 'SH'. 
        partners-partn_numb    = ls_data-kunnr_t.
        if ls_data-region is not initial or ls_data-city1 is not initial.
          select single adrnr from kna1 into (lv_adrnr)
            where kunnr = ls_data-kunnr_t.
          if sy-subrc eq 0.
            partners-ADDR_LINK = lv_adrnr.
            partners-ADDR_ORIG = 'B'.
          endif.
        endif.
        append partners.
        schedules_in-itm_number = ls_data-posnr.
        schedules_in-sched_line = '0001'.
        schedules_in-req_qty    = ls_data-kwmeng.
        append schedules_in.
        schedules_inx-itm_number = 'X'.
        schedules_inx-sched_line = 'X'.
        schedules_inx-req_qty    = 'X'.
        schedules_inx-updateflag = 'X'.
        APPEND schedules_inx.
        if ls_data-region is not initial or ls_data-city1 is not initial.
          partner_address-ADDR_NO = lv_adrnr.
          partner_address-region = ls_data-region.
          partner_address-city   = ls_data-city1 .
          append partner_address.
        endif.
        CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT2'
          EXPORTING
               order_header_in               = header_in
               ORDER_HEADER_INX              = header_inx
          IMPORTING
               SALESDOCUMENT                 = v_vbeln
          tables
               RETURN                        = return
               ORDER_ITEMS_IN                = items_in
               ORDER_ITEMS_INX               = items_inx
               order_partners                = partners
               ORDER_SCHEDULES_IN            = schedules_in
               ORDER_SCHEDULES_INX           = schedules_inx
               PARTNERADDRESSES              = partner_address.
        loop at return where type ca 'AXEW'.
          concatenate lv_hata ' ' return-type ':' return-message into lv_hata.
        endloop.
    Note: İ found the link http://scn.sap.com/thread/348707 but it didnt work.

    Thanks all of you for directions. i solved the problem. there are to ways to do that ;
    1. Create the order and than change the required fields with this bapi, BAPI_SALESORDER_CHANGE
    2. Get the customer infos and add a new partner roles 'WE' with the same kunnr and than give the infos to the partneraddresses, i solved with this way and working very good for me. maybe some needs the solution
    here the code
      if ls_data-region is not initial or ls_data-city1 is not initial.
          partners-partn_role    = 'WE'.  """""""
          partners-partn_numb    = ls_data-kunnr_t.
          select single * from kna1 into CORRESPONDING FIELDS OF ls_kna1
               where kunnr = ls_data-kunnr_t.
          if sy-subrc eq 0.
               partners-ADDR_LINK = '9999999'.
               partners-address = ls_kna1-adrnr.
               partners-ADDR_ORIG =   'B'.
          endif.
          append partners.
    endif.
    if ls_data-region is not initial or ls_data-city1 is not initial.
          partner_address-ADDR_NO = '9999999'.
          partner_address-region = ls_data-region.
          partner_address-city   = ls_data-city1 .
          partner_address-city_no   = ls_data-city_code .
          partner_address-NAME  = ls_kna1-name1.
          partner_address-NAME_2  = ls_kna1-name2.
          partner_address-TEL1_NUMBR  = ls_kna1-telf1.
          partner_address-FAX_NUMBER  = ls_kna1-telfx.
          partner_address-COUNTRY  = ls_kna1-land1.
          append partner_address.
    endif.

  • Schedule date changing with change in ship-to-party address

    Hi Experts,
    When ship-to-party address in the "Partners" (tab_pg) is changed from one country to the other in the header level, the confirmed quantity date is being changed automatically in the Schedule lines (tab_pg).
    Any help is highly appreciated........

    Hi Sunil,
    Whenever the ship to party is changed on the Sales order the Country (picked from ship to party master) will be redetermined. Few other parameters being redetermined are Shipping point, route, transit time etc because of the Ship-To-party(partner receiving the goods) chnages in Sales order. According to that the above parameters will be changed in SO.
    Hope this helps you.
    Thanks
    Arun

  • Header text is not changing when ship to party has changed

    Hello Team,
    I am facing one issue when ship to party has changed in sales order the header text is not re determining automatically,
    I have read some posts and found that using standard its not possible we need to write enhancement for that.
    I have written below code to change the header text but facing some issues, can you please help me on to resolve this issues.
    I am calling 'RV_TEXT_COPY' FM inside the include FV45PFAP_VBAP_FUELLEN_TEXTE ,
    then its saving header text correctly, but this include is calling whenever I click on Header Text tab,
    if suppose if I am changing ship to party and I am not clicking on Header Text tab then this FM will not call this is an issue
    and one more issue is even in screen data is changing after calling RV_TEXT_COPY FM
    but STXH table is not updating, its updating the first value when we created the order.
    Can any one tell me how to solve this issue, Thanks in advance!

    Hi Mac,
    I think the following user exits can help you. In the Include MV45AFZZ use the below exit points,
    1) USEREXIT_MOVE_FIELD_TO_VBKD
    2) USEREXIT_SAVE_DOCUMENT_PREPARE
    try to write your code logic here.
    Regards,
    Satish

  • Assign different ship to party for each material in a sales order in CRM?

    Hi all,
    I need to create a sales order in CRM, such that the sales order contains more than 100 materials at item level and each material should be shipped to a different ship to party.
    That is for 100 materials in sales order I need to ship to 100 different customers.
    The 100 ship to partyu2019s are maintained for the business partner in relation ships tab in /nBP.
    The CRM configuration is done in such a way that when we enter a material while creating a sales order in CRM,u2026u2026.a window pops up asking us to select the ship to party for that material.
    No I need to replicate this programmatically. I generated a sales order in CRM programmatically using BAPI_SLSTRANSACT_CREATEMULTI. u2026 Now I need to make changes such that I have a provision to assign ship to party for each materialu2026
    How can I do this? Can any one tell me if there is a BAPI or Function Module available so that I can assign a different ship to party for each material in sales order?
    Regards,
    Jessica Sam

    Here is sample code. In that highlighted portion is different. check this out
    DATA: ls_partner TYPE crmt_partner_com,
            ls_input_fields TYPE crmt_input_field,
            lt_fieldname TYPE crmt_input_field_names_tab,
            ls_fieldname LIKE LINE OF lt_fieldname.
      ls_partner-ref_handle = p_iv_handle.
      ls_partner-ref_partner_handle = 1.
      ls_partner-ref_kind = 'A'.
      ls_partner-display_type = 'BP'.
      ls_partner-no_type = 'BP'.
      ls_partner-kind_of_entry = 'C'.
    licensee
      ls_partner-partner_fct = '00000069'.
      ls_partner-partner_no = w_but000-partner.
      INSERT ls_partner INTO TABLE gt_partner.
    Bill to party
      IF NOT w_con_header-billtoparty IS INITIAL.
        ls_partner-partner_fct = '00000003'.
        ls_partner-partner_no = w_but001-partner.
        INSERT ls_partner INTO TABLE gt_partner.
      ENDIF.
      IF w_con_header-billtoparty IS INITIAL.
        ls_partner-partner_fct = '00000003'.
        ls_partner-partner_no = w_but000-partner.
        INSERT ls_partner INTO TABLE gt_partner.
      ENDIF.
    Employee
      ls_partner-partner_fct = '00000014'.
      ls_partner-partner_no = w_con_header-empresp.
      INSERT ls_partner INTO TABLE gt_partner.
      +*lsinput_fields-ref_handle = p_iv_handle.*+_
      +*lsinput_fields-ref_kind = 'A'.*+_
      ls_input_fields-logical_key = ls_partner-ref_partner_handle.
      ls_input_fields-objectname = 'PARTNER'.
      ls_fieldname-fieldname = 'DISPLAY_TYPE'.
      INSERT ls_fieldname INTO TABLE lt_fieldname.
      CLEAR ls_fieldname.
      ls_fieldname-fieldname = 'KIND_OF_ENTRY'.
      INSERT ls_fieldname INTO TABLE lt_fieldname.
      CLEAR ls_fieldname.
      ls_fieldname-fieldname = 'NO_TYPE'.
      INSERT ls_fieldname INTO TABLE lt_fieldname.
      CLEAR ls_fieldname.
      ls_fieldname-fieldname = 'PARTNER_FCT'.
      INSERT ls_fieldname INTO TABLE lt_fieldname.
      CLEAR ls_fieldname.
      ls_fieldname-fieldname = 'PARTNER_NO'.
      INSERT ls_fieldname INTO TABLE lt_fieldname.
      CLEAR ls_fieldname.
      ls_input_fields-field_names = lt_fieldname.
      INSERT ls_input_fields INTO TABLE gt_input_fields.

Maybe you are looking for

  • Check numbers for individual invoices in PAYR

    Hey Folks: I have 5 invoices cleared against one ZP document ( clearing document) with payment method being check. I could not find the check information for the invoice line items which got cleared against ZP document in PAYR table. Would someone gi

  • Show not selected anchor points (and connect)

    Hello. Every now and then I have the problem in Illustrator that I want to connect two anchor points with the pen tool. The two anchor points belong to different objects. Is there any way to always show all anchor points. Today I have to select one o

  • Can you export actions?

    I have recorded some actions in Photoshop and placed them in my own Actions group. I know they are there because I can use them when I open Photoshop but I am unable to find them anyplace on my system (I work on a Mac but I am not sure that is import

  • How to remove Gmail "sent message" label

    Hi all, I am using Lion in one of my Mac and I found one problem I am using my Gmail account in Lion Mail When I use Lion Mail to send/reply a mail, Gmail on brower will show a "sent message" label on that mail. What should I do to prevent it? I mean

  • In hotel room, wifi will not give web page to login with safari or other web browser

    I reinstalled mountain lion thinking it might have something to do with college internet settings but still cannot login. Support desk for the network say that other mac pro computers are not having this problem. I can use my iPad, iPod and Windows P