EXIT_SAPLVEDA_001 for IDOC_INPUT_ORDERS

Hi All,
I have written an exit ZXVEDU03 for function module IDOC_INPUT_ORDERS but the program flow is not entering the exit while processing the Idoc though the project for it is activated.
Neither the system is allowing to put any breakpoint in the code written in the exit.
Please reply back soon.....
Thank You,
Regards,

Hi,
Have you created a project (CMOD) and assigned enhancement VEDA0001?
If you have then please ensure you have activated the project and components (Path: CMOD -> Enter custom project -> Select Component option -> Change -> Activate).
Also try to set break point in exit ZXVEDU03 with the following statement.
BREAK <your user ID>.
Regards,
Ferry Lianto

Similar Messages

  • EXIT_SAPLVEDA_001 for transferring Sales order data

    Hello, i have enhanced tables VBAK and VBAP for containing Z* fields. The field and the value will be transferred in the idoc  ORDERS05 segment E1EDK35.
    at header level:
    E1EDK35-CUSADD will contain the name of the field(e.g ZFIELD)
    E1EDK35-CUSADD_BEZ will contain the value of the fields (e.g 500)..
    at item level
    E1EDP01 -> E1EDP35-CUSADD will contain the name of the field(e.g ZFIELD)
                        E1EDP35-CUSADD_BEZ will contain the value of the fields (e.g 100).
    I have to use the EXIT_SAPLVEDA_001 for transferring the values of the new fields.
    Which logic should i apply so that the data gets transferred to VBAK/VBAP.
    So far for header data:
    IF SEGMENT-SEGNAM = 'E1EDK35'.
      S_VBAK =  SEGMENT-SDATA.
    IF S_VBAK-CUSADD = 'ZFIELD1'.
       DXVBAK-ZFIELD1 = S_VBAK-CUSADD_BEZ.
    ENDIF.

    Hello, i have enhanced tables VBAK and VBAP for containing Z* fields. The field and the value will be transferred in the idoc  ORDERS05 segment E1EDK35.
    at header level:
    E1EDK35-CUSADD will contain the name of the field(e.g ZFIELD)
    E1EDK35-CUSADD_BEZ will contain the value of the fields (e.g 500)..
    at item level
    E1EDP01 -> E1EDP35-CUSADD will contain the name of the field(e.g ZFIELD)
                        E1EDP35-CUSADD_BEZ will contain the value of the fields (e.g 100).
    I have to use the EXIT_SAPLVEDA_001 for transferring the values of the new fields.
    Which logic should i apply so that the data gets transferred to VBAK/VBAP.
    So far for header data:
    IF SEGMENT-SEGNAM = 'E1EDK35'.
      S_VBAK =  SEGMENT-SDATA.
    IF S_VBAK-CUSADD = 'ZFIELD1'.
       DXVBAK-ZFIELD1 = S_VBAK-CUSADD_BEZ.
    ENDIF.

  • Error in sales order creation using FM IDOC_INPUT_ORDERS

    Hi experts,
    I am using  FM IDOC_INPUT_ORDERS for IDoc processing for creating sales order.
    I have added customized fields over VA03 screen and to VBAP table.
    I am using user exit EXIT_SAPLVEDA_001 for populating these additional fields.
    Here I am writing below code for customized segment:
      WHEN 'Z1EDP01'.
        x_Z1EDP01 = segment-sdata.
        xvbap-ZZNETWR   = x_Z1EDP01-ZZNETWR.
        xvbap-ZZTAX     = x_Z1EDP01-ZZTAX.
        xvbap-ZZGRSWR   = x_Z1EDP01-ZZGRSWR.
        Move-Corresponding xvbap to dxvbap.
    After this, sales order is getting created but these additional fields are not populated over the VA03 screen. Can you tell me whats wrong in code or any configuration error?
    Thanks,
    ~Sachin

    DXVBAP is an internal table for this exit, where do you modify the line of this itab. (can you post the code with the READ TABLE dxvbap and MODIFY wa/fs statements)
    ([Note 753153 - FAQ: Customer-functions in IDOC_INPUT_ORDERS|https://service.sap.com/sap/support/notes/753153])
    Regards,
    Raymond

  • EXIT_SAPLVEDA_001 segments update

    Any body done the coding inside EXIT_SAPLVEDA_001 for updating or modifying any of the segments please let me know
    Thanks
    Umesh

    if you want to make this exit effective for certain message types use this statement
    CHECK contrl-mestyp EQ 'ORDERS' .  
    for manupulation of data follow as below..
    CASE segment-segnam.
    when 'E1edk01'.
       logic
    when 'E1EDKA1'.
    MOVE segment-sdata TO s_e1edka1.
       logic
    etc.............

  • Creating a Purchase Order using ORDERS05 Idoc

    Hi Experts,
    I need to create a purchase order using ORDERS05 Idoc, with the data I am using a sales order is gettig created but I need to create a PO insted of SO.
    Please let me know what is difference between a PO and SO while using ORDERS05. Also please let me know what are all the fields that needs to chaged in the Idoc.
    Thanks,
    Suma

    Hi,
       I'm looking at a similar problem, can we use ORDERS05 IDOC basic type to create a Purchase Order?
       What is the inbound processing FM?  I tried IDOC_INPUT_ORDRSP, but it seem to only allow changes to a PO, and not creation of a PO.
       For IDOC_INPUT_ORDERS FM this one seem to only create Sales Orders?
       Which inbound FM should i be using?
    Regards.

  • Enhancement VEDA0001 - Component EXIT_SAPLVEDA_006

    I have a couple of questions regarding this :
    1. When this Component runs, has the IDoc already been populated / mapped with all the relevant data coming from the Inbound File? I'm a little confused since this Component is to set the Order Type; but my understanding is that by the time this is running the IDoc has already been mapped. Can I change the value of one of the segments at this point?
    2. My Incoming File will not have the Order Type that I need for this incoming request. How would I code this in this Component?
    Is it as simple as just entering the following lines in the Exit?
    If condition is met.
       E1EDK14-QUALF = '012'.
       E1EDK14-ORGID = 'ZABC'.
    endif.
    Does someone has a simple example of how they have used this Component?
    Thanks for your help

    Hi,
    If you want to update the IDOC segment - E1EDK14, with values for ORGID(which in turn will update XVBAK runtime variable later), then you should be using EXIT_SAPLVEDA_001 for segment E1EDK01 and modifying segment E1EDK14...this is not suggested,
    however if you want to decide the Order type based on the input values in the IDOC then use EXIT_SAPLVEDA_006 and in this exit you just need to update DXVBAK-AUART which is a changing parameter and you do not have to change E1EDK14.
    Regards,
    Chen

  • IDOC PO Type

    Hi
    Is there a way by which we can differentiate IDOC coming through EDI or FAX via a third party system?? let me know
    Also can we differentiate an IDOC based on PO TYPE??
    Thanks

    1) First question: Yes there is the way.
    Go to Header Sales order>Purchase order data>Purchase order type-->
    You can add what ever PO type say
    For YEDI-->For EDI.
    For Manual and Fax-->DFUE.
    If EDI it is EDI Order
    map E1EDK14-->"13" PO Type to YEDI(If length is not suffiecient then assign number)
    and later maintain this number in table and in user exit look up number and assign number to YEDI.
    You can use exit EXIT_SAPLVEDA_001 for lookup. I think mostly not needed.
    Also can we differentiate an IDOC based on PO TYPE??
    I am not sure exactly what you mean.
    For fax order is automatically posted or manual entry ?
    "Reward point if usefull"
    Thanks,
    Narayan

  • Manual price condition item for the Idoc IDOC_INPUT_ORDERS

    Hello,
    I need to inform the item manual price using the function module for IDOCs IDOC_INPUT_ORDERS. I am trying by the segment E1EDP05, field Price, but it doesn´t work properly.
    Thanks in advance
    Regards

    Manuel,
    Merely putting the 'price' into a segment-field won't result in good result. You will need to (potentially)populate a few more fields to tell SAP what you want changed. Here is an example, I have a Condition Type called 'Z123' which is a manual condition record. It has been defined as a 'dollar-off' based discount (as opposed to a percentage etc). If I want to push through a discount of, say, $1.00 per unit then I will be populating the following fields within E1EDP05:
    KSCHL - 'Z123'
    KRATE - '2.21'
    MEAUN - 'EA'
    KOEIN - 'NZD'
    Try that and see how you get on. Also check your EDI config around the handling of Messages for Inbound Orders.
    Here's another hint... Simulate what you want to achieve by creating a sales order manually on the system with the relevant condition types populated and then trigger an outbound IDoc. Take a look at the E1EDP05 segment of the outbound IDoc and it will effectively tell you what you need to populate and where to populate it.
    Since I'm on a roll and feeling altruistic, here's another hint for you... Use WE19 and use the 'Inbound function module' icon and from the dialogue box select the 'Process in the Foreground'. As this function module is effectively a dirty old BDC wrapped around a SAP standard FM, you can step through it and see how it is behaving...
    If you are still having problems, let me know, and I will help you out as much as I can.
    Cheers,
    Paul...

  • EXIT_SAPLVEDA_001 address mapped for STRS2

    Even though the structure dxvbadr is filled with desired values, these values are not reflecting on the sales orders.
    The initial values before triggering user exit, are only being reflected on the sales order. I wondering why.
    Why the sales order header data is not showing modified address values.
    Any guesses, suggestions ??
    I tried using EXIT_SAPLEDA_002 in addition to this and add the strs2 as a field to bdc data but it dit work.
    can somebody pls tell me how to achieve this.... <Priority normalized by moderator>.
    Edited by: Vinod Kumar on Aug 11, 2011 2:07 PM

    Sorry wrong post!!.
    BR
    Dep
    Edited by: DeepakNandikanti on Aug 11, 2011 11:16 AM

  • IDOC_INPUT_ORDERS segment E1EDKA1 is inheriting values from default

    I'm trying to use a user exit in IDOC_INPUT_ORDERS ... function group VEDA.
    What I want to do is clear the WE (ship to) DXVBADR segment and fill it with a diferent destination.
    My problem is that some of the fields are overwritten by the customer address settings when it was created with transaction XD01.I can't seem to get any control over many of them. When I examine the code in IDOC_INPUT_ORDERS, I can see why. Many fields, example HAUSN aren't checked. They just get over-written by the default customer settings from XD01.
    EXIT_SAPLVEDA_001 and EXIT_SAPLVEDA_002 don't seem to work.
    If I could get control over EXIT_SAPLVEDA_002, I could modify the bdc lines for the ship to party. But, that seems very error prone to me.
    Has anyone else encountered this problem?

    I couldn't find any "official" way to do it. So, I used EXIT_SAPLVEDA_002 to blow away all of the fields on the ship to address screen and rebuild it. This probably isn't the most elegant way to do it. But, it works for me and has been stable in my production system.
    P.S.
    I can't get my code pasting to format correctly.
    I'm surrounding it by
    but it isn't working today.
    You may need to claw your way through this mess.
    * FUNCTION EXIT_SAPLVEDA_002.
    *&  Include           ZXVEDU04
    *{   INSERT         ES1K900037                                 
    *"*"Lokale Schnittstelle:
    *"       IMPORTING
    *"             VALUE(DXVBAK) OPTIONAL
    *"             VALUE(DVTCOMAG) OPTIONAL
    *"             VALUE(DLAST_DYNPRO) OPTIONAL
    *"             VALUE(DXMESCOD) LIKE  EDIDC-MESCOD OPTIONAL
    *"       TABLES
    *"              DXBDCDATA STRUCTURE  BDCDATA OPTIONAL
    *"              DXVBAP OPTIONAL
    *"              DXVBEP OPTIONAL
    *"              DYVBEP OPTIONAL
    *"              DXVBADR OPTIONAL
    *"              DYVBADR OPTIONAL
    *"              DXVBPA STRUCTURE  VBPAVB OPTIONAL
    *"              DXVBUV OPTIONAL
    *"              DIDOC_DATA STRUCTURE  EDIDD OPTIONAL
    *"              DXKOMV OPTIONAL
    *"              DXVEKP OPTIONAL
    *"              DYVEKP OPTIONAL
    *"       EXCEPTIONS
    *"              USER_ERROR
    *&==============================================================
    *&                         MODIFICATION LOG
    *&==============================================================
    *& Developer    : Ed Baker (ebaker)
    *& Date         : 5 November 2009
    *& Change Marker: ejb091105
    *& CTS request  : 800899
    *& Transport    : DE1K980565
    *& Description
    *& Added:
    *&  [1] Protection for NAME4 segments to preserve previous
    *&      user exit functionality
    *&  [2] Added insert of NAME3 segment
    " EXIT_SAPLVEDA_002
    data: ta_bdcdata            like bdcdata occurs 0.
    data: ts_bdcdata            like bdcdata.
    *>>>>>>>>>> Save NAME4 segment ejb091105 <<<<<<<<<<<START<
    *"05.11.2009 06:57:13
    * Holding table for NAME4 segments
    * these need to be preserved for compatability with
    * previous user ext.
    data: ta_bdcdata_name4      like bdcdata occurs 0.
    data: ts_bdcdata_name4      like bdcdata .
    *>>>>>>>>>> Save NAME4 segments ejb091105 <<<<<<<<<<<END<
    data: ta_idoc_data          like edidd occurs 0 .
    data: ts_idoc_data          like edidd.
    data: tmp_data              like bdcdata.
    data: v_we_index            like sy-tabix.
    data: v_v09c_index          like sy-tabix.
    data: v_addr1_begin         like sy-tabix.
    data: v_addr1_end           like sy-tabix.
    data: v_index               like sy-tabix.
    data: v_lines               type i.
    data: v_string              type string.
    data: v_sich_found          type c.
    data: st_e1edka1            like e1edka1.
    data: st_vbak               like vbak.
    data: ra_vkorg like RANGE OF tvko-vkorg.
    data: rs_vkorg like LINE OF ra_vkorg.
    *& Build range table of allowed sales orgs
    refresh ra_vkorg[].
    rs_vkorg-sign = 'I'.
    rs_vkorg-option = 'EQ'.
    rs_vkorg-low = '0010'.
    rs_vkorg-high = space.
    APPEND rs_vkorg to ra_vkorg.
    rs_vkorg-sign = 'I'.
    rs_vkorg-option = 'EQ'.
    rs_vkorg-low = '0020'.
    rs_vkorg-high = space.
    APPEND rs_vkorg to ra_vkorg.
    rs_vkorg-sign = 'I'.
    rs_vkorg-option = 'EQ'.
    rs_vkorg-low = '0070'.
    rs_vkorg-high = space.
    APPEND rs_vkorg to ra_vkorg.
    st_vbak = dxvbak.
    *>>>>>>>>>> Wrapper for NAME4 check ejb091105 <<<<<<<<<<<START<
    *"05.11.2009 08:25:40
    "check st_vbak-vkorg in ra_vkorg .
    if st_vbak-vkorg in ra_vkorg.
    *>>>>>>>>>> Wrapper for NAME4 check ejb091105 <<<<<<<<<<<END<
      " VKORG check passed. Go ahead and convert the inputs
      " to internal tables with structures.
      ta_bdcdata[] = DXBDCDATA[].
      ta_idoc_data[] = DIDOC_DATA[].
      " Get the ship to address information
      READ TABLE ta_idoc_data into ts_idoc_data
        with key segnam = 'E1EDKA1'
                 sdata+0(2) = 'WE'.
      IF sy-subrc = 0.
        st_e1edka1 = ts_idoc_data-sdata.
      ENDIF.
      " If the NAME1 field is blank, the default ship to address
      " is the same as the customer. Don't do anything. Just leave.
      check st_e1edka1-name1 ne space.
      " Wait until the SICH (SAVE) code is reached before doing
      " anything with the TA_BDCDATA table
      LOOP AT  ta_bdcdata into ts_bdcdata .
        if ts_bdcdata-fnam = 'BDC_OKCODE'
          and ts_bdcdata-FVAL = 'SICH'.
          v_sich_found = 'X'.
        endif.
      ENDLOOP .
      " the ta_bdcdata itab is stable once the SICH ok_code is found
      " you can go ahead and
      " process it and not have to worry about looping through it
      " multiple times
      IF v_sich_found = 'X'.
    *  >>>>>>>>>> Preserve NAME4 segment ejb091105 <<<<<<<<<<<START<
    *  "05.11.2009 07:01:15
      " Preserve any NAME4 segment for compatability
      " with previous user exit.
          LOOP AT ta_bdcdata into ts_bdcdata
            where fnam = 'NAME4'.
            ts_bdcdata_name4 = ts_bdcdata.
          ENDLOOP.
    *  >>>>>>>>>> Preserve NAME4 segment ejb091105 <<<<<<<<<<<END<
      " First: find the line that says WE ship-to information is nex
          LOOP AT ta_bdcdata into ts_bdcdata .
            IF ts_bdcdata-program = 'SAPLV09C'.
              v_index = sy-tabix + 1 .
              read table ta_bdcdata INTO tmp_data
                index v_index .
              IF sy-subrc = 0.
                v_we_index = v_index .
                exit.
              ENDIF.
            ENDIF.
          ENDLOOP.
      " Second: find the line where the addr1_data segments start
      LOOP AT ta_bdcdata into ts_bdcdata .
        if sy-tabix > v_we_index.
          IF ts_bdcdata-program = 'SAPLV09C'.
            v_addr1_begin = sy-tabix + 1.
            exit.
          ENDIF.
        ENDIF.
      ENDLOOP.
      " Third: find the BDC_OKCODE for the last addr1_data
      LOOP AT ta_bdcdata into ts_bdcdata .
        IF sy-tabix > v_addr1_begin.
          IF  ts_bdcdata-fnam = 'BDC_OKCODE'
          and ts_bdcdata-fval = 'ENT1'.
            v_addr1_end = sy-tabix - 1 .
          ENDIF.
        ENDIF.
      ENDLOOP.
      " Fourth: delete all of the ADDR1_DATA lines
      " program SAPLV09C and screen 5000
      if v_addr1_begin > 0.
       " v_addr1_end
        delete ta_bdcdata
         from v_addr1_begin to v_addr1_end.
    *  &============================================================
    *  &============================================================
      " Fifth: build up whatever you want
    *  &============================================================
    *  &============================================================
          clear ts_bdcdata.
          ts_bdcdata-dynpro = '0000'.
          ts_bdcdata-fnam   = 'ADDR1_DATA-NAME1'.
          ts_bdcdata-fval   = st_e1edka1-name1.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          if st_e1edka1-name2 is initial.
            ts_bdcdata-fnam   = 'ADDR1_DATA-NAME2'.
            ts_bdcdata-fval   = ''.
          else.
            ts_bdcdata-fnam   = 'ADDR1_DATA-NAME2'.
            ts_bdcdata-fval   = st_e1edka1-name2 .
          endif.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
    *  >>>>>>>>>> Add the NAME3 segment ejb091105 <<<<<<<<<<<START<
    *  "05.11.2009 07:41:58
    *  & Add the NAME3 segment. It's used sometimes
          if st_e1edka1-name3 is initial.
            ts_bdcdata-fnam   = 'ADDR1_DATA-NAME3'.
            ts_bdcdata-fval   = ''.
          else.
            ts_bdcdata-fnam   = 'ADDR1_DATA-NAME3'.
            ts_bdcdata-fval   = st_e1edka1-name3 .
          endif.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
    *  >>>>>>>>>> Add the NAME3 segment ejb091105 <<<<<<<<<<<END<
    *  >>>>>>>>>>> Preserve NAME4 segment ejb091105 <<<<<<<<<<<<STAR
    *  "05.11.2009 07:10:29
    *  & Insert the preserved NAME4 segment
          IF not ts_bdcdata_name4 is initial.
            ts_bdcdata-fnam = 'ADDR1_DATA-NAME4'.
            ts_bdcdata-fval = ''.
          else.
            ts_bdcdata-fnam = 'ADDR1_DATA-NAME4'.
            ts_bdcdata-fval = ts_bdcdata_name4-fval.
          ENDIF.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
    *  >>>>>>>>>>> Preserve NAME4 segment ejb091105 <<<<<<<<<<<<END<
          ts_bdcdata-fnam   = 'ADDR1_DATA-STREET'.
          ts_bdcdata-fval   = st_e1edka1-stras.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
         if st_e1edka1-land1 = 'US'.
          ts_bdcdata-fnam   = 'ADDR1_DATA-HOUSE_NUM1'.
          ts_bdcdata-fval   = st_e1edka1-hausn.
         else.
          ts_bdcdata-fnam   = 'ADDR1_DATA-HOUSE_NUM1'.
          ts_bdcdata-fval   = ''.
         endif.
         insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
         add 1 to v_addr1_begin.
          ts_bdcdata-fnam   = 'ADDR1_DATA-CITY1'.
          ts_bdcdata-fval   = st_e1edka1-ort01.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          ts_bdcdata-fnam   = 'ADDR1_DATA-CITY2'.
          ts_bdcdata-fval   = st_e1edka1-ort02 .  " implement county
                                                  " ejb091118
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          if st_e1edka1-land1 = 'US'.
            ts_bdcdata-fnam   = 'ADDR1_DATA-REGION'.
            ts_bdcdata-fval   = st_e1edka1-regio.
          else.
            ts_bdcdata-fnam   = 'ADDR1_DATA-REGION'.
            ts_bdcdata-fval   = ''.
          endif.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          if st_e1edka1-land1 ne 'US'.
            ts_bdcdata-fnam   = 'ADDR1_DATA-TAXJURCODE'.
            ts_bdcdata-fval   = '' .
          endif.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          ts_bdcdata-fnam   = 'ADDR1_DATA-TIME_ZONE'.
          ts_bdcdata-fval   = ''.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          ts_bdcdata-fnam   = 'ADDR1_DATA-POST_CODE1' .
          ts_bdcdata-fval   = st_e1edka1-pstlz.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          ts_bdcdata-fnam   = 'ADDR1_DATA-COUNTRY'.
          ts_bdcdata-fval   = st_e1edka1-land1.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          IF st_e1edka1-telf1 ne space.
            ts_bdcdata-fnam   = 'SZA1_D0100-TEL_NUMBER'.
            ts_bdcdata-fval   = st_e1edka1-telf1 .
          else.
            ts_bdcdata-fnam   = 'SZA1_D0100-TEL_NUMBER'.
            ts_bdcdata-fval   = ''.
          ENDIF.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          ts_bdcdata-fnam   = 'SZA1_D0100-TEL_EXTENS'.
          ts_bdcdata-fval   = ''.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
          if st_e1edka1-PFACH ne space.
           ts_bdcdata-fnam   = 'ADDR1_DATA-PO_BOX'.
           ts_bdcdata-fval   = st_e1edka1-PFACH.
          else.
            ts_bdcdata-fnam   = 'ADDR1_DATA-PO_BOX'.
            ts_bdcdata-fval   = ''.
          endif.
          insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
          add 1 to v_addr1_begin.
    *  " all remaining fields on the ship to screen will be blank.
    *  *    ts_bdcdata-fnam = 'EXTENSION1'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam = 'EXTENSION2'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam = 'PO_BOX_CTY'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam = 'PO_BOX_LOC'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam = 'PO_BOX_REG'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam = 'POST_CODE2'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam = 'POST_CODE3'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam = 'REMARK'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam = 'TIME_ZONE'.
    *  *    ts_bdcdata-fval = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
    *  " Fill in all of the SZA1_D0100 fields
    *      IF st_e1edka1-telf1 ne space.
    *        ts_bdcdata-fnam   = 'SZA1_D0100-TEL_NUMBER'.
    *        ts_bdcdata-fval   = st_e1edka1-telf1 .
    *      else.
    *        ts_bdcdata-fnam   = 'SZA1_D0100-TEL_NUMBER'.
    *        ts_bdcdata-fval   = ''.
    *      ENDIF.
    *      insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *      add 1 to v_addr1_begin.
    *      ts_bdcdata-fnam   = 'SZA1_D0100-MOB_NUMBER'.
    *      ts_bdcdata-fval   = ''.
    *      insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *      add 1 to v_addr1_begin.
    *      ts_bdcdata-fnam   = 'SZA1_D0100-FAX_NUMBER'.
    *      ts_bdcdata-fval   = ''.
    *      insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *      add 1 to v_addr1_begin.
    *      ts_bdcdata-fnam   = 'SZA1_D0100-FAX_NUMBER'.
    *      ts_bdcdata-fval   = ''.
    *      insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *      add 1 to v_addr1_begin.
    *      ts_bdcdata-fnam   = 'SZA1_D0100-SMTP_ADDR'.
    *      ts_bdcdata-fval   = ''.
    *      insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *      add 1 to v_addr1_begin.
    *  *    ts_bdcdata-fnam   = 'SZA1_D0100-DEFLT_COMM'.
    *  *    ts_bdcdata-fval   = ''.
    *  *    insert ts_bdcdata into ta_bdcdata index v_addr1_begin .
    *  *    add 1 to v_addr1_begin.
      endif.
      DXBDCDATA[] = ta_bdcdata[]. "restore the passed parameter
      ENDIF.
    endif. " end of st_vbak test
    *}   INSERT
    loop at DXBDCDATA where FNAM = 'ADDR1_DATA-NAME4'.
      DXBDCDATA-FNAM = 'ADDR1_DATA-STR_SUPPL1'.
      Modify DXBDCDATA.
    endloop.

  • Problem in Idoc extension for PREQCR02

    Hi all,
    While extending Basic type PREQCR02 getting error "Action is not possible for generated Idoc types"
    Is it not possible to extend Idoc PREQCR02?
    Regards,
    Suresh.D

    Hi Suresh,
    The function exit and the include what you found is to read data from the IDOC segment into either internal table or structure.
    That's the first step which you have done is part of the below set:-
    EXIT_SAPLVEDA_001 & ZXVEDU03
    Now you need to populate the which you have read from the idoc into the document for that you need to write the code in the below set. The below one is a function exit which will be called during the BDC. You can see this below
    Aufruf Transaktion Auftragerfassung VA01                             *
    call transaction Order Entry VA01                                    *
            CASE xaprau.
    at line number 131 in the function module IDOC_INPUT_ORDERS.
    EXIT_SAPLVEDA_002 & ZXVEDU04
    Please let me know if you still have any further queries.
    Thanks,
    Mahesh.

  • Problem in Idoc extension for ORDERS05

    HI all,
    Am facing problem in inbound idoc, we have extended the Idoc ORDERS05 with one custom segment, and written the code in user exit EXIT_SAPLVEDA_001 and include ZXVEDU03 exit is triggering properly, sales orderis genarted successfull, but z-fileds are not updating in VBAK table,
    so plz help....
    Regards,
    Suresh.D
    Edited by: suresh dameruppula on Oct 20, 2009 2:39 PM

    Hi Suresh,
    The function exit and the include what you found is to read data from the IDOC segment into either internal table or structure.
    That's the first step which you have done is part of the below set:-
    EXIT_SAPLVEDA_001 & ZXVEDU03
    Now you need to populate the which you have read from the idoc into the document for that you need to write the code in the below set. The below one is a function exit which will be called during the BDC. You can see this below
    Aufruf Transaktion Auftragerfassung VA01                             *
    call transaction Order Entry VA01                                    *
            CASE xaprau.
    at line number 131 in the function module IDOC_INPUT_ORDERS.
    EXIT_SAPLVEDA_002 & ZXVEDU04
    Please let me know if you still have any further queries.
    Thanks,
    Mahesh.

  • Segment for WBS element in Inbound Sales Order Idoc

    Hi gurus,
    I am trying to create an inbound idoc for sales order ' VA01'. I need to populate WBS element in the item level under Account Assignment Tab. I am using ORDERS05 basic type. Please help to find which segment to use for WBS element. Waiting for your reply. Please help.
    Regards,
    Satyajit

    Hello,
            As far as I know, there is no Segment / Field definition in ORDERS05 for WBS Element as it is not mandatory information to be filled in order for the Sales Order to be Complete. So, you need to create an Extension of the IDoc Type ORDERS05. For your requirement, here is the Approach I have.
    1. Create an extension for IDoc Type ORDERS05 to ZORDER05 with a Custom Segment Z1EDP01 in which you'll have the Custom Field Name VBAP-PS_PSP_PNR which is the WBS Element field in VBAP Table.
    2. Now, use the Customer Exit EXIT_SAPLVEDA_001 in the Enhancement VEDA0001 in which you can actually populate the Field WBS Element that would be already available in the Inbound IDoc to store it in a Work Area. As you are aware, you'll need to create a Project in CMOD for the same.
    3. Export the same to some MEMORY ID 'XXX'.
    4. Come back to the Selection Program for ORDER05 which is IDOC_INPUT_ORDERS in which you'll find the below CASE Statement.
        CASE xaprau.
              WHEN ' '.
                PERFORM call_va01_new_orders USING ok.
              WHEN 'Q'.
    Aufruf Transaktion Auftragerfassung VA01 mit Bezug auf Angebot
    call transaction Order Entry VA01 with refer to quote number.
                PERFORM call_va01_new_orders_angbt USING ok.
              WHEN 'C'.
    Aufruf Transaktion Auftragerfassung VA01 mit Bezug auf Kontrakt
    call transaction Order Entry VA01 with refer to contract number
                PERFORM call_va01_new_orders_contk USING ok.
              WHEN 'L'.
    5. Now, since our Standard Order Type (VBAK-VBTYP) is 'C',
        we'll have to choose the Subroutine for the 'C' Option.
    6. In this Subroutine, there is another Subroutine va01_dynpro_kopf_kaufmann_kde2 which is for populating Custom Dynpro Fields for the Sales Order. So, we need to choose the same Subroutine inside which we have to Create an Enhancement Implementation.
    7. In this Enhancement Implementation (Implicit), we have to IMPORT the value of the WBS Element which was exported in the Customer Exit.
    8. Check if it is initial. If it is not, then Call the Perform as below.
         IF NOT WA_Z1EDP01 IS INITIAL. "Checking if the Segment
                                                           " is Empty
       PERFORM DYNPRO_SETZEN USING 'COBL-PS_POSID' WA_Z1EDP01-ZZWBSELEMENT.
    ENDIF.
    9. Since the Sales Orders are posting using BDC here, by calling the above Subroutine DYNPRO_xxx, we are appending our Custom Segment / Field value to the BDC_DATA table.
    10. In Step 8, I've given the Notation for Work Area. It will also be applicable when there are multiple Line Items. All you have to do is to EXPORT an Internal Table instead of Work Area and use the same here for each Line Item.
    11. I've given you above procedure because I've worked on similar requirement in which I had to populate the Special Processing Indicator instead of WBS Element.
    Hope it would be helpful for you.
    Thanks and Regards,
    Venkat Phani Prasad Konduri

  • EXIT_SAPLVEDA_001 Query

    Hi,
    I have created an extension to the standard ORDERS05 idoc to include a couple of extra flags.
    I have extended the VBAK structure to include the 2 new fields and I have added code within EXIT_SAPLVEDA_001 to populate xvbak with the values from this flag as follows:-
    IF segment-segnam = 'ZE1EDK01'.
      s_ze1edk01 = segment-sdata.
        hxvbak-ZZFULFILLALL = s_ze1edk01-zzfulfillall.
        hxvbak-ZZPRICEMISMATCH = s_ze1edk01-zzpricemismatch.
        MOVE hxvbak TO dxvbak.
    ENDIF.
    However, later in the Sales order useexit, I want to set reason for rejection based on the values of these flags.
    I have debugged the code and I can see that the xvbak structure is correctly updated within EXIT_SAPLVEDA_001  when an idoc comes in but the values in the xvbak structure don't seem to be available in the xvbak structure within the Sales Order Userexit (MV45AFZZ).
    Can anyone advise on whether this should be possible and if so, what I am doing wrong.
    Thanks,
    Ruby

    Sorry, I should have been clearer.
    It's a customer exit and the definition is attached below. This is called from within FM IDOC_INPUT_ORDERS which is called when an idoc comes in. When this is called, xvbak is passed into dxvbak.
    When I debug this, I can see the dxvbak and hence the xvbak fields being populated as I expect but by the time I get into the Sales Order User Exit (MV45AFZZ) the new xbvak fields are blank.
    I just wondered whether I have missed a step somewhere.
    FUNCTION EXIT_SAPLVEDA_001.
    ""Lokale Schnittstelle:
    *"       IMPORTING
    *"             VALUE(SEGMENT) LIKE  EDIDD STRUCTURE  EDIDD OPTIONAL
    *"             VALUE(DVTCOMAG) OPTIONAL
    *"             VALUE(DXMESCOD) LIKE  EDIDC-MESCOD OPTIONAL
    *"             VALUE(CONTRL) LIKE  EDIDC STRUCTURE  EDIDC OPTIONAL
    *"       TABLES
    *"              DXBDCDATA STRUCTURE  BDCDATA OPTIONAL
    *"              DXVBAP OPTIONAL
    *"              DXVBEP OPTIONAL
    *"              DYVBEP OPTIONAL
    *"              DXVBADR OPTIONAL
    *"              DYVBADR OPTIONAL
    *"              DXVBPA STRUCTURE  VBPAVB OPTIONAL
    *"              DXVBUV OPTIONAL
    *"              DD_FLAG_P OPTIONAL
    *"              DXKOMV OPTIONAL
    *"              DXVEKP OPTIONAL
    *"              DYVEKP OPTIONAL
    *"       CHANGING
    *"             VALUE(DXVBAK) OPTIONAL
    *"             VALUE(DD_FLAG_K) OPTIONAL
    *"       EXCEPTIONS
    *"              USER_ERROR
      INCLUDE ZXVEDU03.
    ENDFUNCTION.

  • EDI for creation of Sales Order and sending copy of Invoice

    Hello Experts,
    I am working on EDI. We have a scenario, where the purchase order created in the 3rd party system has to be converted into a sales order in our SAP system.
    Then, the regular flow would follow uptil delivery and creation of invoice in SAP.
    We have to send a copy of this Invoice back to the 3rd party system.
    So, in effect, we would have EDI at two points, while capturing the PO from the 3rd party and another when sending a copy of the Invoice back to the 3rd party.
    Please advise on how to go about implementing EDI in the above mentioned scenarios.
    Regards,
    Divyata

    Use EDI 850 Process code ORDE FM IDOC_INPUT_ORDERS for PO (Inbound)
    use EDI 810 Process code SD09  FM IDOC_OUTPUT_INVOIC for Invoic (Outbound)
    Edited by: srini korada on Jun 9, 2011 4:51 PM

Maybe you are looking for

  • My Macbook Pro (15 Inch) turns off randomly!!

    My Macbook Pro (15 Inch) turns off randomly (Usually when it triggers graphic card) Here I have a problem report. can anyone tell me what is happening???? Interval Since Last Panic Report:  45976 sec Panics Since Last Report:          15 Anonymous UU

  • How is it possible for me to turn in my old iPhone 4s for the new iphone 5 for the lowest price

    how is it possible for me to turn in my old iPhone 4s for the new iphone 5 for the lowest price

  • Moving Elements 9 to Macbook?

    When I bought my old stationary PC I got a bundled version of Elements 9 (Photoshop and Premiere) with it. Since then I mainly use a Macbook for most of my media production and now of course I'd like to be able to move my Elements license to my Macbo

  • 9/80 Work Schedule in California

    Hi We need to implement 9/80 schedule for non-exempt employees in California. This has to go live with first pay period begin date Nov 1st ( Friday ) Noon , First period end date is Nov 15th ( Friday ) Noon and first check date is Nov 22nd. We are un

  • Why PO Item does not appear when return GR?

    Dear Gurus, The scenerio is, A standard PO with 30 items. The PO is released and complete received by MB01 103, 105. When return GR by MIGO GR 122, the PO items do not appear except one item. If use MB01, the same. Why? Pls advice. Thanks. Regards, D