Sales Order User Exits - configurable materials !?

I have been tasked with investigating the following issue and if it can be solved via ABAP/User Exits. Users in an already live system are entering Sales Orders ( VA01 )with multiple Configurable Material line items and have to repeatedly enter the same characteristic values in each line item ( by entering Item Details >> Configuration ). They want to enter a set of characteristic values in the first line item and then have them defaulted into any further items. I have looked at the standard user exits in particular USEREXIT_MOVE_WORKAREA_TO_SDWA. Has anybody attempted anything similar to this !? Any ideas ?
Possible issues are:
1. How do I find the characterictic values from the 1st line item. ie. they haven't been saved yet, are they in a temp area similar to XVBAP for normal sales order line items !?
2. Are there are any suitable user exits in the Configuration side of things ( Function Group CEI0 !? ) to effect any changes the defaults. There are some BADIs in the code but they are not yet in use !?

Hi Jonathan!
I had a different requirement with sales orders and configuration, but this forced me into long debugging of behavior of all these exits.
1) Characteristics can't be read.
ad 1) in configuration it's possible to call function modules. Here (inside the configuration) values of characteristics are available and can be saved in global data of a Z-function module. This is later (in same transaction) available (like import/export).
2) I would propose to use functions of characteristics (as mentioned, it's possible to execute own function modules in configuration). It's possible to default values (meaning: output of your function is only done, if characteristic is not set) based on global data of Z-function module.
As long as a global memory is used, no interaction with other transactions has to be feared.
You don't need user exits (but a lot of coding).
You need to change the customizing of configuration - probably a huge task, because I guess you have a huge configuration (otherwise users wouldn't ask for maintenance help).
Regards,
Christian

Similar Messages

  • Change Confirmed Qty in Sales Order User exit/ATP User exit

    HI
    We have a requirement to change the ATP Qty for certain meterials & Order Types  duing sales Order User exit(FORM USEREXIT_MOVE_FIELD_TO_VBEP.? ) or ATP User exit.( ATP...OUT?).
    Is this ok to update the XVBEP in FORM USEREXIT_MOVE_FIELD_TO_VBEP of MV45AFZZ ?
    Our requirement will be like this, for one order type ZSAL( and for certain Materials)  we need to reserve 4 qty, if any order comes with 10 qty and the confimed qty is only 6( total available stock at present) , then we should only confirm  2 qty for the other order type( For Non ZSAL Order Type), and reserve the 4 QTY for ZSAL Order Type.
    If there are multiple schedule lines for an Item, we need to reduce the qty equally( as possible) from all schdule lines.
    i.e. date1 qty 4
         date2 qty 6,
    in  this case we should confirm  Date1 QTY 2, date2 qty 4, so that the remaining 4 will be reserved for ZSAL Order type.
    Whats the Best way to achieve this ?
    Edited by: agrud agrud on Sep 8, 2011 4:01 AM

    Hi Agrud,
    Did you check the possibilities with configuration.If it is not possible with configuration then you can use that exit.Before i used this but only to display not to change any thing.
    Regards,
    Madhu.

  • PO Creation from Sales Order User Exit

    Hi,
    I have a business requirement where I need to  create a Stock Transport Order (STO) for a particular kind of sales order. I outlined different options for achieving this functionality.
    1. Trigger a workflow for creating STO.
    2. Configure it an EDI output for sales orders. Using the EDI document, create STO in the same system.
    3. Create STO using BAPI from the sales order exit 'USEREXIT_SAVE_DOCUMENT'.
    I am trying to understand the issues if I go with option of creating STO from sales order user-exit. I tested it and it is working fine. But what concerns is me transaction integrity. In other words I am trying to  execute another transaction within a transaction. Both Transactions (VA01 and ME21N/BAPI) may be trying to access same tables. Anyways I havent see any potential overlap.
    I would like to know anybody implemented such a solution?
    What could be the potential issues? Does it really affect transaction integrity?
    Thanks A Lot
    Anil

    I would also be concerned with the possibility of the order failing to update AFTER you call the BAPI.  You could create a custom output type that processes on order create for that order type.  You could add your BAPI call to the processing routine of the output type.

  • Need All Sales Order user exit

    Neeed all Sales Order user exits

    Hi,
    Check these Exits and their corresponding Programs
    User Exits In Sales Document Processing
    This IMG step describes additional installation-specific processing in sales document processing. In particular, the required INCLUDES and user exits are described.
    Involved program components
    System modifications for sales document processing affect different areas. Depending on the modification, you make the changes in the program components provided:
    MV45ATZZ
    For entering metadata for sales document processing. User-specific metadata must start with "ZZ".
    MV45AOZZ
    For entering additional installation-specific modules for sales document processing which are called up by the screen and run under PBO (Process Before Output) prior to output of the screen. The modules must start with "ZZ".
    MV45AIZZ
    For entering additional installation-specific modules for sales document processing. These are called up by the screen and run under PAI (Process After Input) after data input (for example, data validation). The modules must start with "ZZ".
    MV45AFZZ and MV45EFZ1
    For entering installation-specific FORM routines and for using user exits, which may be required and can be used if necessary. These program components are called up by the modules in MV45AOZZ or MV45AIZZ.
    User exits in the program MV45AFZZ
    The user exits which you can use for modifications in sales document processing are listed below.
    USEREXIT_DELETE_DOCUMENT
    This user exit can be used for deleting data which was stored in a separate table during sales document creation, for example, if the sales document is deleted.
    For example, if an additional table is filled with the name of the person in charge (ERNAM) during order entry, this data can also be deleted after the sales order has been deleted.
    The user exit is called up at the end of the FORM routine BELEG_LOESCHEN shortly before the routine BELEG_SICHERN.
    USEREXIT_FIELD_MODIFICATION
    This user exit can be used to modify the attributes of the screen fields.
    To do this, the screen fields are allocated to so-called modification groups 1 - 4 and can be edited together during a modification in ABAP. If a field has no field name, it cannot be allocated to a group.
    The usage of the field groups (modification group 1-4) is as follows:
    Modification group 1: Automatic modification with transaction MFAW
    Modification group 2: It contains 'LOO' for step loop fields
    Modification group 3: For modifications which depend on check tables or on other fixed information
    Modification group 4: is not used
    The FORM routine is called up for every field of a screen. If you require changes to be made, you must make them in this user exit.
    This FORM routine is called up by the module FELDAUSWAHL.
    See the Screen Painter manual for further information on structuring the interface.
    USEREXIT_MOVE_FIELD_TO_VBAK
    Use this user exit to assign values to new fields at sales document header level. It is described in the section "Transfer of the customer master fields into the sales document".
    The user exit is called up at the end of the FORM routine VBAK_FUELLEN.
    USEREXIT_MOVE_FIELD_TO_VBAP
    Use this user exit to assign values to new fields at sales document item level. It is described in the section "Copy customer master fields into the sales document".
    The user exit is called up at the end of the FORM routine VBAP_FUELLEN.
    USEREXIT_MOVE_FIELD_TO_VBEP
    Use this user exit to assign values to new fields at the level of the sales document schedule lines.
    The user exit is called up at the end of the FORM routine VBEP_FUELLEN.
    USEREXIT_MOVE_FIELD_TO_VBKD
    Use this user exit to assign values to new fields for business data of the sales document. It is described in the section "Copy customer master fields into sales document".
    The user exit is called up at the end of the FORM routine VBKD_FUELLEN.
    USEREXIT_NUMBER_RANGE
    Use this user exit to define the number ranges for internal document number assignment depending on the required fields. For example, if you want to define the number range depending on the sales organization (VKORG) or on the selling company (VKBUR), use this user exit.
    The user exit is called up in the FORM routine BELEG_SICHERN.
    USEREXIT_PRICING_PREPARE_TKOMK
    Use this user exit if you want to include and assign a value to an additional header field in the communication structure KOMK taken as a basis for pricing.
    USEREXIT_PRICING_PREPARE_TKOMP
    Use this user exit if you want to include or assign a value to an additional item field in the communication structure KOMP taken as a basis for pricing.
    USEREXIT_READ_DOCUMENT
    You use this user exit if further additional tables are to be read when importing TA01 or TA02.
    The user exit is called up at the end of the FORM routine BELEG_LESEN.
    USEREXIT_SAVE_DOCUMENT
    Use this user exit to fill user-specific statistics update tables.
    The user exit is called up by the FORM routine BELEG-SICHERN before the COMMIT command.
    Note
    If a standard field is changed, the field r185d-dataloss is set to X. The system queries this indicator at the beginning of the safety routine. This is why this indicator must also be set during the maintenance of user-specific tables that are also to be saved.
    USEREXIT_SAVE_DOCUMENT_PREPARE
    Use this user exit to make certain changes or checks immediately before saving a document. It is the last possibility for changing or checking a document before posting.
    The user exit is carried out at the beginning of the FORM routine BELEG_SICHERN.
    User exits in the program MV45AFZA
    USEREXIT_MOVE_FIELD_TO_KOMKD
    Use this user exit to include or assign values to additional header fields in the communication structure KOMKD taken as a basis for the material determination. This is described in detail in the section "New fields for material determination".
    USEREXIT_MOVE_FIELD_TO_KOMPD
    Use this user exit to include or assign values to additional item fields in the communication structure KOMPD taken as a basis for the material determination. This is described in detail in the section "New fields for material determination".
    USEREXIT_MOVE_FIELD_TO_KOMKG
    Use this user exit to include or assign values to additional fields in the communication structure KOMKG taken as a basis for material determination and material listing. This is described in detail in the section "New fields for listing/exclusion".
    USEREXIT_MOVE_FIELD_TO_KOMPG
    Use this user exit to include or assign values to additional fields in the communication structure KOMPG taken as a basis for material determination and material listung. This is described in detail in the section "New fields for listing/exclusion".
    USEREXIT_REFRESH_DOCUMENT
    With this user exit, you can reset certain customer-specific fields as soon as processing of a sales document is finished and before the following document is edited.
    For example, if the credit limit of the sold-to party is read during document processing, in each case it must be reset again before processing the next document so that the credit limit is not used for the sold-to party of the following document.
    The user exit is executed when a document is saved if you leave the processing of a document with F3 or F15.
    The user exit is called up at the end of the FORM routine BELEG_INITIALISIEREN.
    User-Exits in program MV45AFZB
    USEREXIT_CHECK_XVBAP_FOR_DELET
    In this user exit, you can enter additional data for deletion of an item. If the criteria are met, the item is not deleted (unlike in the standard system).
    USEREXIT_CHECK_XVBEP_FOR_DELET
    In this user exit, you can enter additional data for deletion of a schedule line. If the criteria are met, the schedule line is not deleted (unlike in the standard system).
    USEREXIT_CHECK_VBAK
    This user exit can be used to carry out additional checks (e.g. for completion) in the document header. The system could, for example, check whether certain shipping conditions are allowed for a particular customer group.
    USEREXIT_CHECK_VBAP
    This user exit can be used to carry out additional checks (e.g. for completion) at item level.
    USEREXIT_CHECK_VBKD
    The user exit can be used to carry out additional checks (e.g. for completion) on the business data in the order.
    USEREXIT_CHECK_VBEP
    This user exit can be use to carry out additional checks (e.g. for completion) on the schedule line. During BOM explosion, for example, you may want certain fields to be copied from the main item to the sub-items (as for billing block in the standard system).
    USEREXIT_CHECK_VBSN
    You can use this user exit to carry out additional checks (e.g. for completion) on the serial number.
    USEREXIT_CHECK_XVBSN_FOR_DELET
    In this user exit, you can enter additional criteria for deletion of the serial number. If the criteria are met, the serial number is not deleted (unlike in the standard system).
    USEREXIT_FILL_VBAP_FROM_HVBAP
    You can use this user exit to fill additional fields in the sub-item with data from the main item.
    USEREXIT_MOVE_FIELD_TO_TVCOM_H
    You can use this user exit to influence text determination for header texts. For example, you can include new fields for text determination or fill fields that already exist with a new value.
    USEREXIT_MOVE_FIELD_TO_TVCOM_I
    You can use this user exit to influence text determination for item texts. For example, you can include new fields for text determination or fill fields that already exist with a new value.
    User-Exits for product allocation:
    The following user exits all apply to structure COBL, in which the data for account determination is copied to item level.
    USEREXIT_MOVE_FIELD_TO_COBL
    Option to include new fields in structure COBL.
    USEREXIT_COBL_RECEIVE_VBAK
    Option to assign values from the document header to the new fields.
    USEREXIT_COBL_RECEIVE_VBAP
    Option to supply values from the item to the new fields.
    USEREXIT_COBL_SEND_ITEM
    A changed field can be copied from the structure into the item. You could use the user exit to display a certain field in the account assignment block (see also MV45AFZB).
    USEREXIT_COBL_SEND_HEADER
    A changed field can be copied from the structure to the header (see source text MV45AFZB)
    USEREXIT_SOURCE_DETERMINATION
    You can use this user exit to determine which plant will be used for the delivery. In the standard system, the delivering plant is copied from the customer master or the customer-material info record. If you want to use a different rule, then you must enter it in this user exit.
    USEREXIT_MOVE_FIELD_TO_ME_REQ
    With this user exit you can include additional fields for the following fields:
    EBAN (purchase requisition)
    EBKN (purchase requisition-account assignment)
    USEREXIT_GET_FIELD_FROM_SDCOM
    Option to include new fields for the variant configuration. Fields that are included in structure SDCOM can be processed and then returned to the order.
    USEREXIT_MOVE_WORKAREA_TO_SDWA
    You can use this user exit to format additional work areas for the variant configuration. You will find notes on the user exit in MV45AFZB.
    User-Exits for first data transfer:
    The following user exits can only be used for the first data transfer.
    Note
    Only use the user exits if the names/fields do NOT have the same name.
    USEREXIT_MOVE_FIELD_TO_VBAKKOM
    Option to include additional fields in structure VBAKKOM (communiction fields for maintaining the sales document header)
    USEREXIT_MOVE_FIELD_TO_VBAPKOM
    Option to include additional fields in structure VBAPKOM (communication fields for maintaining a sales item)
    USEREXIT_MOVE_FIELD_TO_VBEPKOM
    Option to include additional fields in structure VBEPKOM (communication fields for maintaining a sales document schedule line)
    USEREXIT_MOVE_FIELD_TO_VBSN
    You can use this user exit to include fields in structure VBSN (scheduling agreement-related change status).
    USEREXIT_MOVE_FIELD_TO_KOMKH
    You can use this user exit to include new fields for batch determination (document header).
    USEREXIT_MOVE_FIELD_TO_KOMPH
    You can use this user exit to include new fields for batch determination (document item).
    USEREXIT_CUST_MATERIAL_READ
    You can use this user exit to set another customer number in the customer material info record (e.g. with a customer hierarchy)
    USEREXIT_NEW_PRICING_VBAP
    Option for entry of preconditions for carrying out pricing again (e.g. changes made to a certain item field could be used as the precondition for pricing to be carried out again). Further information in MV45AFZB.
    USEREXIT_NEW_PRICING_VBKD
    Option for entry of preconditions for carrying out pricing again (e.g. changes to the customer group or price group could be set as the preconditions for the system to carry out pricing again). Further information in MV45AFZB.
    User-Exits in Program MV45AFZD
    USEREXIT_CONFIG_DATE_EXPLOSION
    The BOM is exploded in the order with the entry date. You can use this user exit to determine which data should be used to explode the BOM (explosion with required delivery date, for example).
    User exits in the program FV45EFZ1
    USEREXIT_CHANGE_SALES_ORDER
    In the standard SAP R/3 System, the quantity and confirmed date of the sales document schedule line is changed automatically if a purchase requisition is allocated, and it or the sales document is changed (for example, quantity, date).
    If you want to change this configuration in the standard system, you can define certain requirements in order to protect your sales orders from being changed automatically. Use this user exit for this purpose. Decide at this point whether the schedule lines are to be changed.
    User-Exits in Program RV45PFZA
    USEREXIT_SET_STATUS_VBUK
    In this user exit you can you can store a specification for the reserve fields in VBUK (header status). Reserve field UVK01 could, for example, be used for an additional order status (as for rejections status, etc.).
    The following workareas are available for this user exit:
    VBUK (header status)
    FXVBUP (item status)
    FXVBUV (Incompletion)
    USEREXIT_SET_STATUS_VBUP
    In this user exit you can you can store a specification for the reserve fields for VBUP (item status).
    The following workareas are available for this user exit:
    FXVBAP (Item data)
    FXVBAPF (Dynamic part of order item flow)
    FXVBUV (Incompletion)
    USEREXIT_STATUS_VBUK_INVOICE
    You can use this user exit to influence billing status at header level.
    User exits in the screens
    Additional header data is on screen SAPMV45A 0309, additional item data on screen SAPMV45A 0459. These screens contain the Include screens SAPMV45A 8309 or SAPMV45A 8459 as user exits.
    Fields which are also to be included in the sales document for a specific installation should be included on the Include screens for maintaining. If an application-specific check module is needed for the fields, this can be included in the Include MV45AIZZ. The module is called up in the processing logic of the Include screens.
    For field transports, you do not have to make changes or adjustments.
    Example
    A new field, VBAK-ZZKUN, should be included in table VBAK.
    If the check is defined via the Dictionary (fixed values or check table) the field must be included with the fullscreen editor in the Include screen SAPMV45A 8309. In this case, no change has to be made to the processing logic.
    User Exits in Program MV45AFZ4
    USEREXIT_MOVE_FIELD_TO_KOMK
    You can use this user exit to add or edit additional header fields in the communication structure - KOMK- for free goods determination. For more information, see the New Fields for Free Goods Determination IMG activity.
    USEREXIT_MOVE_FIELD_TO_KOMP
    You can use this user exit to add or edit additional item fields in the communication structure KOMP for free goods determination. For more information see the New Fields for Free Goods Determination IMG activity.
    User Exits in the SAPFV45PF0E and SAPFV45PF0C Programs
    EXIT_SAPFV45P_001
    You can use this user exit to decide whether intercompany billing data is used in the profitability segment for cross-company code sales, or whether the data comes from external billing (external customer, sales data from the selling company code.
    Reward points if helpful.
    Regards
    Ravi

  • Name of the structure needed for sales order user exit

    Hi,
    I am planning to write a user exit which will insert the data into my ztable the moment the new sales order is created and is saved.
    I have identified FORM USEREXIT_SAVE_DOCUMENT as the necessary user exit. But the problem is that while inserting the data into the ztable I cannot insert the data from vbak as the data will be inserted into this table after the SO is saved.
    Thus I need to identify a structure which is used to populate the vbak table so that it simultaneously inserts the data in the ztable as well. Can anyone help me with the name of the structure so that these fields i.e. vbeln, vkorg, vtweg, spart are inserted into my ztable?
    Also need to know how to convert the net value i.e. vbak-netwr in Indian Rupees as it gets stored as Dollars ....
    Thanks,
    Vinod.

    Hi,
    One of the structure being used is RV45A, there are several other str's being used as well for various calculations,
    check out program SAPMV45A for the same.
    & in order to convert vbak-netwr to rupees use the below statemetnt,
    WRITE vbak-netwr TO zvbak-netwr CURRENCY INR.
    Regards,
    Raghavendra
    Message was edited by:
            raghavendra ay

  • Sales Order - user exit at item level

    I am new in writing user-exits. Pls do share your exp !
    When creating a sales order I encounter error, system says "Enter batch number".
    We basically create batch when doing GoodsReceive for Production Orders. At this time the Material Revision is copied as Batch into MCHB table.
    For example:
    Material ABC has the below,
    Rev    Batch
    A        A
    B        B
    C        blank
    If I create a SO for part ABC for Rev C, it does not allow me becos batch does not exists. But my SO should be allowed to be copy C into the batch field in VBAP.
    Pls let me know if we must create custom user-exit rather than modifying std.SAP user-exit for Sales Order processing (MV45AFZZ).
    Is there any contraints using the batch field in SO? As I came to know that the problem is when creating a Purchase Order  it allows to enter free text in batch field but SO doesn’t allow. Is't?
    Is there any standard way to config the system such that SO will bypass the existence checking of the batch
    Pls share !
    Pri

    Hi, but inplace of Batch we only enter the Revision of the material. Becos rev-batch relationship is 1-1, meaning is rev is A, the batch will be A too.
    We just use the batch field to represent the revision
    Rev    Batch
    A        A
    B        B
    C        blank
    I  can enter A in SO item batch field because system check that batch A exists
    I can enter B in SO item batch field because system check that batch B exists
    But I can’t enter C in SO item batch field because system check that batch C doesn’t exist
    Wondering how the system might know the batch is actually my revision. Not sure if I use User  EXIT to move “C” into VBAP-CHARG, will it give me error message because it will find out that there is no C batch
    Your views !

  • Ztable not updating in sales order user exit

    Hi Genius Abapers.
    We want to take text ID data of sales order into Ztable. For taking the data we have used user exit in sales order. Now the problem is if we go through debug mode then the Ztable is updating but if we remove the break point Ztable is not getting updated.
    Please give solution for this problem
    Regards
    Narayana

    Hi Gurus,
            I am basically from SD and we used commit statements in the programme and this is the code we used
    Include name --- MV45AF0B_BELEG_INITIALISIEREN
    **********************************Code Addd by paresh 8.10.2007 starts *******************************
      DATA : BEGIN OF itab_so OCCURS 0,
             vbeln LIKE vbap-vbeln,
             posnr LIKE vbap-posnr,
             spras LIKE t002t-spras,
             END OF itab_so.
      DATA : BEGIN OF itab_so1 OCCURS 0,
             vbeln LIKE vbap-vbeln,
             posnr LIKE vbap-posnr,
             spras LIKE t002t-spras,
             END OF itab_so1.
      DATA : BEGIN OF it_tabid OCCURS 0,
             tdid LIKE stxh-tdid,
             tdspras like stxh-tdspras,
             END OF it_tabid.
      DATA : is_stxh TYPE stxh.
      DATA g_header TYPE string .
      DATA wa_plain_text TYPE zplain_text.
      DATA t_lines LIKE tline OCCURS 0 WITH HEADER LINE.
      DATA g_item(16)." type i.
      data :it_ztable type table of  ZPLAIN_TEXT .
      data wa_ztable type zplain_text.
      data flag.
    *****************************Read Header text***************************************
    *loop at vbak.
       itab_so1-vbeln = vbak-vbeln.
       itab_so1-posnr = vbak-posnr.
       itab_so1-spras = vbak-wklnd.
       APPEND itab_so1.
       CLEAR itab_so1.
    ENDLOOP.
    refresh it_tabid.
    clear it_tabid.
    refresh it_ztable.
    clear it_ztable.
      LOOP AT xvbap.
        itab_so-vbeln = vbak-vbeln.
        itab_so-posnr = xvbap-posnr.
        itab_so-spras = xvbap-wklnd.
        APPEND itab_so.
        CLEAR itab_so.
      ENDLOOP.
    LOOP AT itab_so.
        SELECT tdid tdspras FROM stxh INTO TABLE it_tabid WHERE tdobject = 'VBBK' AND tdname = vbak-vbeln  .
    ENDLOOP.
    *loop at it_ztable into wa_ztable.
      LOOP AT itab_so.
        LOOP AT it_tabid.
          is_stxh-tdobject = 'VBBK'.
          is_stxh-tdname   = vbak-vbeln.
          is_stxh-tdid     = it_tabid-tdid.
          is_stxh-tdspras  = it_tabid-tdspras.
          CALL FUNCTION 'READ_TEXT'
            EXPORTING
              id                      = is_stxh-tdid
              language                = is_stxh-tdspras
              name                    = is_stxh-tdname
              object                  = is_stxh-tdobject
            TABLES
              lines                   = t_lines
            EXCEPTIONS
              id                      = 1
              language                = 2
              name                    = 3
              not_found               = 4
              object                  = 5
              reference_check         = 6
              wrong_access_to_archive = 7
              OTHERS                  = 8.
          IF sy-subrc = 0.
            LOOP AT t_lines.
              CONCATENATE g_header t_lines-tdline INTO g_header SEPARATED BY space.
            ENDLOOP.
            wa_plain_text-application = 'SO'.
          wa_plain_text-key1 = itab_so-vbeln.
            wa_plain_text-key1 = vbak-vbeln.
            wa_plain_text-key2 = 'HDR'.
            wa_plain_text-sub_application = it_tabid-tdid.
            wa_plain_text-text = g_header.
            wa_plain_text-last_date = sy-datum.
            MODIFY zplain_text FROM wa_plain_text .
       wait up  to  60 seconds.
             commit work.
            CLEAR: wa_plain_text.
            CLEAR : g_header,t_lines.
            refresh t_lines.
          ENDIF.
      if sy-subrc <> 0.
       delete from zplain_text where key1  = vbak-vbeln    and
                                  key2  = itab_so-posnr    and
                                  SUB_APPLICATION = it_tabid-tdid.
                                   commit work.
       endif.
        ENDLOOP.
      ENDLOOP.
    *endloop.
    Please do me the needfull
    Regards
    Manam.Narayana

  • Blocked field in Sales Order when using configurable materials

    Hi everyone,
    I have noticed that every time I insert a configurable material in a Sales Order Line, after pressing ENTER and having valuated the associated characteristics, the Material and Position Type fields stay blocked so I cannot change the material in this position.
    According to the process I am implementing, I would need in certain cases to change the material (replacing the configurable for a non-configurable one).
    I would be very grateful if someone could help me to avoid that these fields get blocked or at least to know the reason.
    Thanks in advance and best regards.
    Ben.

    I don't have any experience with configurable materials, but it seems that in this case you'll need to delete the line (or the lines) and re-enter them with the proper type of material.

  • Sales Orders User Exits

    Dear colleagues,
    Are there any user exits that I can invoke at the time of deleting a line item from a sales order?
    Ideally, I would like the user exit to check the status of production order and prompt the user if the associated production order can be deleted.  If the user chooses to retain the production, system should retain the production order although the associated sales order / lineitem is deleted.
    Regards,
    Pavan

    I could Figure it out.
    Thanks,
    Kannan

  • ABAP: Sales Orders user-exit

    Hi all,
    I have a functional requirement and I would like to know if a simple technical solution can be applied.
    My functional requirement :
    I create a Sales Order and according the Ship-to I've populated, some custom fields in Sales Order Header have to be automatically retrieved from a specific table and displayed in the screen.
    During this process, the user can often change the Ship-to and at each time, the system has to retrieve the corresponding data and displayed them into custom fields of the Sales Order.
    I wouls like to know:
    1- if the user-exit "MOVE_FIELD_TO_VBAK" can be used for retrieving the data according the Ship-to
    2- which user-exit I can use to display in custom screen of the Sales Order, the retrieved data related to the Ship-to
    Do not hesitate to propose all possible solutions, because I'm not aware about the techncial possibilities in Sales Orders.
    Thanks in advance.
    Have a nice day!

    Hi
    The first, take in account the recommendations in SAP Note 178328 - Problems due to incorrect user exits in SD.
    Read the comments for these subroutines.
    Go to SE38 for SAPMV45A and you can see all userexits
    Other source. Look for notes in the marketplace (service.sap.com/notes) related with these userexits.
    I hope this helps you
    Regards
    Eduardo
    PD: check in include MV45AFZB the subroutines USEREXIT_CHECK* for avoid changes.
    In include MV45AFZZ, read the comments for userexit_field_modification. You can avoid modifications for some fields.

  • Save Sales Order - user exit

    Please help me to find user exit or badi for tracking saving Sales Order event.
    User exit must be called before data is saved.

    T. Code SE38
    Type MV45AFZZ and click display.....then hit the search Icon and type USEREXIT_SAVE_DOCUMENT__PREPARE...it will take you.
    Else you can used SMOD also to go to this userexit
    Regards
    Sai

  • Sales Order User Exit

    While saving the Sales order , i want to add one more line item internally . Is there is any exits availble ? Pls Help .
    Points will be rewarded .

    In Prg name : MV45AFZZ u can use the user exit name : userexit_save_document_prepare.
    Madhavi

  • Manually trigger Availability Check in the Sales Order User Exit MV45AFZZ

    Hi All,
    As per the normal scenario where sales orders are created and the schedule line delivery dates are determined.
    Based on some business logic for few customers we need to change the delivery priority and confirmation delivery date.
    We are implementing this logic in the user exit MV45AFZZ in the routine USER_EXIT_SAVE_DOCUMENT_PREPARE.
    The availability check logic is already implemented by then. Now we have scenarios where the date redetermined by the custom logic is greater than the one determined by the standard availability check done by SAP.
    We have changed the values of the field VBEP-EDATU as per our logic but we still have 2 lines in the schedule line data where the requested date is greater than the confirmed date.
    This can be tackled if we can redo the Availability Check.
    Can someone provide pointers on how can we trigger the availability check manually in the code.
    Regards,
    Karthik

    What was the solution?

  • BAPI for Creating Sales Order For Variant Configuration Materials

    Dear Gurus,
    Before posting this thread, we have referred many SDN threads, OSS notes and other sites for any sort of help..but no success..All threads and other referrals are not much of help as they are kind of incomplete( Perhaps, we are unable to understand them..no offense).
    Few checked threads on this subjects are:
    http://scn.sap.com/thread/34590
    http://scn.sap.com/thread/851070
    http://scn.sap.com/community/abap/blog/2014/04/23/update-vc-variant-configuration-data-using-standard-bapi-in-sales-order
    http://scn.sap.com/community/abap/blog/2014/07/15/creating-orders-with-variant-configured-items-using-bapisalesordercreatefromdat2
    http://scn.sap.com/community/abap/blog/2014/04/23/update-vc-variant-configuration-data-using-standard-bapi-in-sales-order
    http://scn.sap.com/thread/120144
    OSS: 549563
    Well, we're using the BAPI (BAPI_SALESORDER_CREATEFROMDAT2) which creates the sales order successfully but without the characteristic values in line items.
    We're passing data to the following parameters - ORDER_CFGS_REF, ORDER_CFGS_INST, ORDER_CFGS_VALUE to create the variant config but not able to see it getting created.
    Pls find attached BAPI coding document for your reference.
    If you could throw any light on this issue will be of great help for us.
    Thank You in Advance!!!
    Reg,
    Jagan-SD.

    Jagan nath
    Try below.
    you would need miimum of 3 segments to pass variant config data using this bapi
    ORDER_CFGS_REF for each configurable item
    POSEX = ITEM #
    CONFIG_id , root_id - Start with 1 and increment it for each configurable line item
    ORDER_CFGS_INST
    CONFIG_ID - from above
    INST_ID - Start with 1 and increment it for each configurable line item
    OBJ_TYPE = "MARA'
    CLASS_TYPE = '300'
    OBJ_KEY = material #
    ORDER_CFGS_VALUE
    CONFIG_ID for the item, INST_ID for the item
    charc for characteristic value
    VALUE for characteristic value
    Reference thread
    How to Fill Configuration Data in BAPI BAPI_SALESORDER_CREATEFROMDAT2
    Hope it will solve your issue.
    Thanks
    Ritesh

  • Sales order user exit to make item quantity zero

    Hello friends ,
    Here is my requirement . When I am creating or changing the
    sales order I need to check wether the material is discontinued
    or not and if discontinued and if discontinued I need to make the
    quantity as zero . Can you please hekp me out with this .
    We are on version ECC 5.0
    Can anyone tell me if this will resolve my issue .
    <b>userexit_save_document_prepare</b>
    Thanks ,
    Varun .

    Hi alll ,
    Finally I had my code in this way in the exit : USEREXIT_SAVE_DOCUMENT_PREPARE
    Here is my code :
    data wmvke like mvke .
    field-symbols : <f_xvbap> type VBAPVB .
    loop at xvbap assigning <f_xvbap>.
    select single * from mvke into wmvke where matnr = xvbap-matnr and
                                   vkorg = vbak-vkorg and
                                   vtweg = vbak-vtweg and
                                   vmsta = '30' .
        if sy-subrc eq 0 .
        <f_xvbap>-kwmeng = <f_xvbap>-kwmeng * 0 .
        <f_xvbap>-updkz = 'U' .
        <f_xvbap>-abgru = 'PR' .
    *    modify xvbap .
        endif .
    endloop .
    In the debug mode while saving the sales order I can see the process going through the code and table xvbap getting executed . But still I do not have any idea on why it is not reflected when I comeout from the debug mode .
    Please help me with this .
    Thanks ,
    Varun .

Maybe you are looking for

  • Error while importing categories to Outlook calendar

    Hi there! I'm sharing an Outlook calendar with my colleagues, and its events are categorized with colors. I found this page for importing the categories to every local machine, and it worked! But for 2 users only were imported three of four categorie

  • App Store, Maps, Safari crashes

    I have an ipod touch -4th generation. Since about a month ago, 3 built-in apps (App store, Maps, Safari) have been crashing. Sometimes the ipod just freezes and the Home and Sleep button become useless for a few seconds. After a few seconds, I have t

  • "BPE_ADAPTER" SYSTEM_FAILURE_INTERNAL

    Hi Experts, I saw the previous blogs on the "BPE_ADAPTER">SYSTEM_FAILURE_INTERNAL failures but i didn't get the solution. My Scenario is SOAP to RFC to FILE with Asyn/Sync Bridge using BPM(Aync Receive, Sync Send,Send ), while I am testing messages a

  • Nokia 6021 - Switching on and off

    I have just received a brand new Nokia 6021 to replace a 6310i which was developing a fault with the on/off switch after 4 years. Well, the 6021 is just about impossible to switch on and off. My thumb is now strained after so many attempts. The only

  • CME 4.0 to 4.2

    Hi All Currently  i am using CME 4.0 on my 2821 ISR Router with IOS 12.4(9)T7. I want to change the CME version to 4.2. What i need to do?? Kindly need your help in this. Thanks