Is it possible to trigger user exit in BDC?

Hi experts,
I am having issue as follows.
when i am successfully creating rework code & UD code through tcode QA11 manually.
If i am doing manually some user exits will be called and there rework code will be generated successfully.
But i have used QA11 in my program using call transaction QA11 in back ground mode.
It is creaing UD code successfully.But rework code also has to be generated in back ground through user exit.
But that is not happening.
But internally my user exits are not calling when i run my program in back ground or fore ground.
Is there any problem of triggering user exists when running BDC in back ground or foreground?
Now i am unable to create rework code through QA11 why because user exists were not calling internally.
Thanks & Regards,
LOKESH GOUD

why dont you keep a break point and debug??

Similar Messages

  • Trigger User-Exit userexit_pricing_prepare_tkomk while changing Billing doc

    Hi Experts,
    Could any one of you let me know how to identify user exit "userexit_pricing_prepare_tkomk" is getting triggered while creating Billing document or while changing Billing document.
    This user exit is being triggered in both the above cases.
    I looked into xvbrk-updkz. No value is getting populated in change mode of Billing document for this field.
    Is there any other field which will be helpful in differentiating these 2 cases.
    Thanks in advance,
    Vinoth

    Hi Vinoth,
    refer to the following link:
    Re: USEREXIT_PRICING_PREPARE_TKOMK in prog. RV60AFZZ
    Hope this will help you...

  • Is it possible to get user exit from st05???

    Hi all,
    One has said me that you can find user exit of a transaction from sql trace, st05.
    I do not believe that, however I wanted to ask you..
    Thanks.

    Hi,
    we can find the badi but not the user exit . u have 2methods for searching userexits
    one frm the tcode-> find programname->package name->gotosmod->give package name and f4 functioanlity->cmod-> give the name u can get it.
    other-> directly from smod and cmod.
    regards,
    Sana.

  • Sales Orders - Add/Delete the Partner should Trigger User Exits

    Hi,
    I have a business requirement to add a new partner or delete or change an existing partner so as to re-determine the route and hence re-direct the goods to appropriate shipping point. This partner is a service agent and not maintained in the Customer Master. These are freely added partners (agents) at the sales order level.
    Once there is a change in the partner functional the sales order level in VA01 or VA02, the user exit logics to be called again so that the route is re-determined based on the newly added or changed partners at the sales order level.
    I am just trying to provide a pop-up screen for user interaction when the sales order partners are modified with buttons 'OK' or 'Cancel'. For OK, the sales order user exits to be called again. For Cancel, the newly added partners need to be deleted.
    Please suggest me a suitable solution. I hope I have made the question correct. Appreciate your help in advance.
    Thanks,
    Kannan.

    I could Figure it out.
    Thanks,
    Kannan

  • User Exit and BDC for ME22N

    Hello All,
    A code has been written in the User exit for Tcode ME22N, Which sets the indicator on PO line item. This has been done by modifying the standard itab POT by using field symbols, because the fields to be modified are shown in display mode in the tcode ME22N and cannot be done in BDC. See the below code in user exit ZXM06U43.
    DATA char(50) VALUE '(SAPLMEPO)POT[]'.
    CLEAR wa_ind.
        FIELD-SYMBOLS <f1> TYPE ANY.
    Move memory of internal table POT to field symbol f1.
        ASSIGN (char) TO <f1>.
    Move content of f1 to internal table i_ind
        i_ind[] = <f1> .
        LOOP AT i_ind INTO wa_ind.
          IF wa_ind-pstyp = '9'.            " Service PO - item category
    IF PO Line item has History per Purchasing Document as 'D'
    Set indicators on, for the line item.
            CLEAR v_cnt.
            SELECT COUNT( * ) INTO v_cnt FROM ent5100
                                         WHERE ebeln = wa_ind-ebeln
                                           AND ebelp = wa_ind-ebelp
                                           AND bewtp = 'D'.
            IF sy-subrc = 0.
              wa_ind-wepos = 'X'.            " Set Goods Receipt Indicator
              wa_ind-webre = 'X'.            " Set GR-based IV Indicator
              wa_ind-lebre = 'X'.            " Set Srv-based IV Indicator
            ELSE.
    *End of addition SAP-20070910104025 - SL36 - D01K963369
              wa_ind-wepos = ' '.            " Clear Goods Receipt Indicator
              wa_ind-webre = ' '.            " Clear GR-based IV Indicator
              wa_ind-lebre = ' '.            " Clear Srv-based IV Indicator
              wa_ind-xersy = ' '.            " Clear ERS Indicator
            ENDIF.                                           
            MODIFY i_ind FROM wa_ind INDEX sy-tabix.
          ENDIF.
        ENDLOOP.
        <f1> = i_ind[].
      ENDIF.          
    ENDIF.
    This code is in production and has been working fine.
    The requirnment is now to make this indicator work for all the Purchase order before this code has been written in the Exit. For this my functional suggests that to write a separate program using BDC for PO change and jus add a period/dot  in the short text and save it. The code has been written, the user exit and the above code is getting triggrred values are updated in internal table correctly.
    However the flags was not set or cleared when seen in the tcode ME22N . This works fine if the tcode me22n is run directly and not working in BDC.
    I have tried with ME22 without enjoy transaction in BDC changing the POT Program to SAPMM06E. It does not work.
    Please help me as why it is not uodating in the table when using BDC.
    Thanks in Advance.
    Senthil Kumar

    Hi All,
    Any luck on this??
    Thanks

  • Is it possible to increase user exit time out for a partcular user

    Dear Sir/madam,
    Is it possible to increase the User Time Out for a Particular user ?
    We do it through RZ10 and as per I know when it is changed, it is effected to all the users.
    Pls advice.
    Thanks,
    Pranab

    Hi Pranab,
    Not possible for a single user.
    Regards
    Ashok Dalai

  • Is it possible to through user exit??

    Hi Gurus,
    i am supplying a material with returnable packaging material to our customer.
    10.  material
    20.  returnable packaging materl
    in a sales order we creating like above line items.
    we are charging rentals for returnable packaging material.
    i would like to know.. line item wise i want a option like yes/no(its relevant for rent or not), because some customer is not applicable for rentals. If the option is "No" it will not link with any other process, if the optiong is "Yes' ,, it will hit some other programme(calculation of rent)..here we need to enter basic details of rents.
    Is it possible ....Please advise...
    Thanks in Advance

    Hi,
    Why don't you try with item category itself. Maintain 2 item categories for this returnable package item, one is relevant for pricing and another not relevant for pricing. Depending on your requirement you can maintain one as default and another as manual.
    Depending on scenario you can change the item category to charge the customer. If it does not require any calculation you will not in need of writing any code. Simply you can create a condition type and maintain condition records for it.
    Hope this will help you.
    Reward if it helps you.
    Thanks
    Venkat Cheedalla.

  • Is it possible to get the fields in to our user exit .....?

    Hi All,
        In the user exit some structures are passed as import parameters in the function module. but we want other than those structure fields in to our user exit. that means those fields are dynamically populated in to the transaction.based on those fields we have to trigger one dialog window. so how to get those fields in to our user exit.
    -Prasanth.M
    Ex: Transaction: IW31/IW32
        Enhancement Name: IWO10009
        Structure Name: CAUFVD.
    But i want these fields ACPOS,WRTTP,BELTP,WRT00 to WRT16. these fields are in PMCO table.but i want these fields before updating the PMCO table,not from the PMCO table. based on these fields we have to trigger user exit.
    Message was edited by:
            prasanth Kumar

    Hi,
    here i am giving my requirement.
    Please look in to this and let me know how to solve the problem.
    1.     Check ordertype
          a.     If ordertype = REP1 set planned cost limit field to 450
          b.     If ordertype = MUT1 set planned cost limit field to 5000
    2.     Check the planned costs for value category KostenTalis
           Check table PMCO for the order
              i.     PMCO-ACPOS = KostenTalis
             ii.     PMCO-WRTTP = 1
             iii.     PMCO-BELTP = 1
             iv.     PMCO-VORGA = KPPP
              v.     PMCO-WERT00 -> PMCO-WERT16, check if one of the fields  WRT00 till WRT16 is filled with a value
         a.     No, exit
         b.     Yes, go to 3
    3.     Are the total costs for Talis > planned cost limit field euro?
         a.     No, do nothing and end this user-exit
         b.     Yes, show the pop-up and place the total planned costs in the variable <costs>
    and already i had given tr and user exit.i think its sufficient to solve the issue.
    still u have any more doubts kindly let me know.
    -Prasanth.M

  • User exit or other enhancements to change the status of the kanban.

    The requested to trigger the movement when the kanban status changed from empty to full.
    if itu2019s possible to use user exit or other enhancements to change the status of the kanban.
    can you please guide me iam new for enhancements.

    I think you're seeing standard SAP behavior.  However, a discussion with your SD/LE functional team member might be beneficial. Personally, I don't think SAP supplies a way to "add back" to that quote.  However, you might develop something that changes the quantity on the quote (essentially adds to the original quantity), based on the fact that a SO line got rejected.

  • User Exit/Badi for CATS

    Hi Experts,
    Our requirement is to trigger an email notification to the Employee after his time sheet is approved using the CATS approval WF.
    We are using the portal to raise the time sheet and approve the same. We want to determine a User Exit/ Badi when the approver clicks on the approved button in the UWL.
    We tried looking into the user exits/badi's etc. given but they are defined only for the R/3 system  using the CATS transaction and not via the portals.
    Could you kindly guide us with any Badi/User Exit that could be used when it is approved via the portal (i.e) when the approver clicks on the approve button in the UWL.
    Cheers,
    Belinda Clarke

    Hi,
    Are you sure that those possible badis or user exit that you found are not also for Portal? Many times there is no difference whether something is done from backend transaction or a portal application - finally the same code/function is used and thus the same badis & user exits are executed. Of course not always, but plenty of times.
    If if you cannot find anything, please check also the possibility to use enhancement. Check which RFC function is called during the approval (put RFC trace on) and put a break point there, and see what the code does and if you could put your stuff into some place.
    Pay attention also the CATSDB table. That includes the cats entries and if remember correctly, you can find the work item ID there for each CATS entry. Maybe you can build some kind of report based on this table to send the emails instead of using some user exit or whatever.
    Regards,
    Karri

  • User Exit or Badi for AS01 at save.

    Hello!
    I need a user exit or badi to validate fields from ANLA and ANLZ tables in AS01 trasaction. This validation is before save.
    I have already check this user exit with no success:
    AAPM0001       
    Integración contabilidad activos fijos/mantenimiento
    AFAR0003       
    Método externo de cambio
    AFAR0004       
    Determinar valores proporcionales en una baja
    AINT0004       
    Modificar importe de contabilización para determinadas áreas
    AINT0005       
    No utilizar dummy debido a verificación sintaxis ampliada
    AISA0001       
    Asignar número de inventario
    AIST0001       
    Intercambiar rango núm.actualiz.datos maestros
    AIST0002       
    Campos de usuario en el maestro de activos fijos
    AMSP0002       
    Determinar tipo de relación entre dos sociedades
    TRAN0001       
    Salida de usuario al transferir inmovilizados
    Thanks in advance!
    Sabrina.

    Hi Sabrina,
    i am not sure about it as you have not explained about your exact requirement for validation in AS01, but please see transaction GGB0 , if you are able to make your validation here, because i don't think it will be possible through any user exits.

  • ME59N - Customize it to change POs?  User Exit?

    Hi all,
    We are using the automatic PO creation program (ME59N) to convert approved requisitions with a fixed source of supply to purchase orders.
    We have scenarios at our company where, after the PO is created and sent to the vendor, a change is to be made, which is usually a new line item that is required.  Our process dictates that every new request must go through a requisition and approval process before it can be converted into a PO or added onto an existing PO.  In this scenario, the user will create a new requisition or add a line item to an existing requisition, and upon approval, will manually drag the new requisition line into an existing PO (we do not want to issue multiple POs to the vendor, we would like to issue a change order instead when it makes sense to). 
    Since me59n runs a couple times a day, the user may sometimes not have time to manually drag the requisition into the existing PO, and when this happens, the system creates a brand new PO and sends it off to the vendor.  This is obviously confusing as the new line item really belongs on an existing PO that was issued to the vendor.
    We were wondering if it was possible, to update the me59n program, to check if the requisition should be included on an existing PO, rather than creating a new PO (we would have the user enter the existing PO# in the requisition in the requirement tracking number field).  If the program found a reference to a PO on the requisition line item, it would then find the relevant PO and add the requisition line as a new line item in the existing PO (i.e. change the PO), rather than create a fresh new PO.
    Obviously this is not standard in ME59n, as ME59n would create a new PO with the requisition.  Is this at all possible via a user exit or badi?  Has anyone came across this requirement and have a solution?  Or at least a recommendation on which user exit/badi that may be used to implement this? 
    Cheers,

    Hi Anupama,
    Try to write the code like this..
    loop at itab_covp.
        select single dlinr belnr from ad01dli INTO AD01DLI-dlinr AD01DLI-belnr
        where belnr =  itab_covp-belnr .
        if sy-subrc <> 0.     "if record doesn't exist
          DELETE t_covp.
        else.                     "If record exist
          SELECT single * from  AD01DLIEF into AD01DLIEF
           where DLINR =  AD01DLI-dlinr and belnr = itab_covp-belnr and dopen <> ''.
           if sy-subrc <> 0.  "if record doesn't exist
             DELETE t_covp.
           endif.
        endif.
    endloop.
      This will be the correct logic for your requirement.
    Thanks,
    Sreenivas Reddy Maddi

  • User exit for same price in RFQ /po

    >The following is a client's requirement :-
    >When we maintain the RFQ document in ME47, the conditions like basic price, discount, freight percentage, etc are getting calculated in the net price but the conditions like freight (Value), insurance (value), packaging (value), surveyor's fees (value) are not getting calculated in the net price for comparision. While all these conditions are getting calculated in the Purchase Order. The user wants that the net value of comparision in RFQ should be the same as in PO. All conditions calculated in PO for item should also be calculated in RFQ document while maintaining quotations.
    >Kindly share if there is any user exit to achieve this. If this is possible without the user exit then please let me know the steps in configuration to achieve this.
    >thanks in advance.
    >AJ

    Please give the navigation or tcode through which we can attach the PO calculation schema to RFQ.
    Thanks in advance.
    >AJ

  • Abap code of user EXIT for my first post on FISCPER_CALC_MONTH or year

    *ZSIGFISCPER Exercice cumulé jusqu'à la période selectionnée par utilisateur
    TABLES: TVARVC.
    DATA: L_S_RANGE TYPE RSR_S_RANGESID.
    DATA : LOC_VAR_RANGE LIKE RRRANGEEXIT,
    v_year like T009B-BDATJ,
    v_per3 like T009B-POPER,
    v_month(3) type c,
    v_initial(7) type c,
    v_date type d,
    w_progcod like tvarvc-low.
    BREAK-POINT.
    CASE I_VNAM.
      WHEN 'ZSIGFISCPER'.
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZP_FIL_FISCPER'.
            CLEAR L_S_RANGE.
            v_year = LOC_VAR_RANGE-LOW(4).
            concatenate v_year '001' into v_initial.
            L_S_RANGE-LOW = v_initial.
            L_S_RANGE-HIGH = LOC_VAR_RANGE-LOW.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'BT'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
      WHEN 'ZSIGVFISCYEAR'.
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZP_FIL_FISCPER'.
            CLEAR L_S_RANGE.
            CLEAR v_year.
            v_year = LOC_VAR_RANGE-LOW(4).
            L_S_RANGE-LOW = v_year.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'EQ'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
    *Sélection de la période 1 par rapport à une période sélectionnée via la variable 'ZP_FIL_FISCPER'
      WHEN 'ZVUEPER1'.
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZP_FIL_FISCPER'.
            CLEAR L_S_RANGE.
            CLEAR v_year.
            v_year = LOC_VAR_RANGE-LOW(4).
            concatenate v_year '001' into v_initial.
            L_S_RANGE-LOW = v_initial.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'EQ'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
    *Sélection de la période 1 par rapport à une période sélectionnée via la variable 'ZSIGFISC'
      WHEN 'ZVUEPER2'.
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZSIGFISC'.
            CLEAR L_S_RANGE.
            CLEAR v_year.
            v_year = LOC_VAR_RANGE-LOW(4).
            concatenate v_year '001' into v_initial.
            L_S_RANGE-LOW = v_initial.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'EQ'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
    Variables pour la requête ZSIGRQ_ZSIGMCM1_01 (Suivi des investissements)
      WHEN 'ZSIGCDR2'.
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZP_FIL_FISCPER'.
            CLEAR L_S_RANGE.
            CLEAR v_year.
            v_year = LOC_VAR_RANGE-LOW(4).
            CONCATENATE v_year '01' '01' INTO v_date.
            L_S_RANGE-LOW = v_date.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'EQ'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
      WHEN 'ZSIGCDMS'. " Date de mise en service
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZP_FIL_FISCPER'.
            CLEAR L_S_RANGE.
            CLEAR v_year.
            v_year = LOC_VAR_RANGE-LOW(4).
            CONCATENATE v_year '01' '01' INTO v_date.
            L_S_RANGE-LOW = v_date.
            CONCATENATE v_year '12' '31' into v_date.
            L_S_RANGE-HIGH = v_date.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'BT'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
      WHEN 'ZSIGHIM'. " Hierarchie
        IF I_STEP = 1. "before the popup
          Clear v_year.
          SELECT SINGLE * FROM TVARVC WHERE NAME EQ 'ZSIG_REF_0APPR_YEAR'.
          IF sy-subrc EQ 0.
            v_year = TVARVC-low.
          ENDIF.
          CLEAR w_progcod.
          SELECT SINGLE * FROM TVARVC WHERE NAME EQ 'ZSIFVA_REF_0PROG_DEF_S'.
          IF sy-subrc EQ 0.
            w_progcod = TVARVC-low.
          ELSE.
            MESSAGE 'Variable ZSIFVA_REF_0PROG_DEF_S is missing in TVARVC' TYPE 'E'.
          ENDIF.
          CONCATENATE w_progcod v_year INTO L_S_RANGE-LOW.
          L_S_RANGE-SIGN = 'I'.
          L_S_RANGE-OPT = 'EQ'.
          APPEND L_S_RANGE TO E_T_RANGE.
        ENDIF.
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZP_FIL_FISCPER'.
            CLEAR L_S_RANGE.
            CLEAR v_year.
            v_year = LOC_VAR_RANGE-LOW(4).
            CLEAR w_progcod.
            SELECT SINGLE * FROM TVARVC WHERE NAME EQ 'ZSIFVA_REF_0PROG_DEF_S'.
            IF sy-subrc EQ 0.
              w_progcod = TVARVC-low.
            ELSE.
              MESSAGE 'Variable ZSIFVA_REF_0PROG_DEF_S is missing in TVARVC' TYPE 'E'.
            ENDIF.
            CONCATENATE w_progcod v_year INTO L_S_RANGE-LOW.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'EQ'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
      WHEN 'ZSIGCAC'. " version
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZP_FIL_FISCPER'.
            CLEAR L_S_RANGE.
            CLEAR v_month.
            v_month = LOC_VAR_RANGE-LOW+4(3).
            IF v_month LE '003'.
              L_S_RANGE-LOW = 'PLA'.
              L_S_RANGE-SIGN = 'I'.
              L_S_RANGE-OPT = 'EQ'.
            ELSEIF v_month LE '008'.
              L_S_RANGE-LOW = 'AC1'.
              L_S_RANGE-SIGN = 'I'.
              L_S_RANGE-OPT = 'EQ'.
            ELSE.
              L_S_RANGE-LOW = 'AC2'.
              L_S_RANGE-SIGN = 'I'.
              L_S_RANGE-OPT = 'EQ'.
            ENDIF.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
      WHEN 'ZSIGDDP'.
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'ZP_FIL_FISCPER'.
            CLEAR L_S_RANGE.
            CLEAR v_year.
            v_year = LOC_VAR_RANGE-LOW(4).
            v_per3 = LOC_VAR_RANGE-LOW+4(3).
            CALL FUNCTION 'LAST_DAY_IN_PERIOD_GET'
              EXPORTING
                I_GJAHR              = v_year
      I_MONMIT             = 00
                I_PERIV              = 'K4'
                I_POPER              = v_per3
              IMPORTING
                E_DATE               = v_date
              EXCEPTIONS
                INPUT_FALSE          = 1
                T009_NOTFOUND        = 2
                T009B_NOTFOUND       = 3
                OTHERS               = 4
            IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
            ENDIF.
            L_S_RANGE-LOW = '20101231'."v_date.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'EQ'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
    Variable Z_DATE_REF_INF_FOUR pour caracteristique 0CALDAY
    Intervalle
      WHEN 'Z_DATE_REF_INF_FOUR'.
        IF I_STEP = 2. "after the popup
          LOOP AT I_T_VAR_RANGE INTO LOC_VAR_RANGE WHERE VNAM = 'Z_DATE_REF_SUP_FOUR'.
            CLEAR L_S_RANGE.
            CLEAR v_date.
            v_date = LOC_VAR_RANGE-low.
           break-point.
            CALL FUNCTION 'SALP_CALC_DATE'
              EXPORTING
                IN_RECTYPE          = 'M'
                IN_NBR_DWXMQY       = '6'
                IN_DATE             = v_date
             IMPORTING
               OUT_DATE            = v_date
            EXCEPTIONS
              OTHER_ERROR         = 1
              OTHERS              = 2
            IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
            ENDIF.
            CALL FUNCTION 'SALP_CALC_DATE'
              EXPORTING
                IN_RECTYPE          = 'Y'
                IN_NBR_DWXMQY       = '-2'
                IN_DATE             = v_date
             IMPORTING
               OUT_DATE            = v_date
            EXCEPTIONS
              OTHER_ERROR         = 1
              OTHERS              = 2
            IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
            ENDIF.
            L_S_RANGE-LOW = v_date.
            L_S_RANGE-SIGN = 'I'.
            L_S_RANGE-OPT = 'EQ'.
            APPEND L_S_RANGE TO E_T_RANGE.
          ENDLOOP.
        ENDIF.
    Variable Z_DATE_REF_INF_FOUR pour caracteristique 0CALDAY
    Intervalle
    Variables pour Production interne
    Intervalle
    Debut - FDUPEYROUX - 11/01/2010
      WHEN 'ZSIGPEROI'.
        IF I_STEP = 2. "after the popup
          CLEAR L_S_RANGE.
          CLEAR v_date.
          READ TABLE I_T_VAR_RANGE INTO LOC_VAR_RANGE
           WITH KEY VNAM = 'ZSIGPERPI'.
          L_S_RANGE-LOW  = LOC_VAR_RANGE-HIGH.
          L_S_RANGE-SIGN = 'I'.
          L_S_RANGE-OPT  = 'EQ'.
          APPEND L_S_RANGE TO E_T_RANGE.
        ENDIF.
      WHEN 'ZSIGPEROI_ENT'.
        IF I_STEP = 2. "after the popup
          CLEAR L_S_RANGE.
          READ TABLE I_T_VAR_RANGE INTO LOC_VAR_RANGE
           WITH KEY VNAM = 'ZSIGPERPI'.
          L_S_RANGE-HIGH = LOC_VAR_RANGE-HIGH.
          L_S_RANGE-LOW  = '1000001'.
          L_S_RANGE-SIGN = 'I'.
          L_S_RANGE-OPT  = 'BT'.
          APPEND L_S_RANGE TO E_T_RANGE.
        ENDIF.
      WHEN 'ZSIGPEROI_P1'.
        IF I_STEP = 2. "after the popup
          CLEAR: L_S_RANGE, v_per3.
          READ TABLE I_T_VAR_RANGE INTO LOC_VAR_RANGE
           WITH KEY VNAM = 'ZSIGPERPI'.
          IF LOC_VAR_RANGE-LOW+4(3) = '001'.
            LOC_VAR_RANGE-LOW(4) = LOC_VAR_RANGE-LOW(4) - 1.
            LOC_VAR_RANGE-LOW+4(3) = '012'.
          ELSE.
            v_per3 = LOC_VAR_RANGE-LOW+4(3) - 1.
            LOC_VAR_RANGE-LOW+4(3) = v_per3.
          ENDIF.
          L_S_RANGE-LOW  = LOC_VAR_RANGE-LOW.
          L_S_RANGE-SIGN = 'I'.
          L_S_RANGE-OPT  = 'EQ'.
          APPEND L_S_RANGE TO E_T_RANGE.
        ENDIF.
      WHEN 'ZSIGPEROI_PINF'.
        IF I_STEP = 2. "after the popup
          CLEAR: L_S_RANGE, v_per3.
          READ TABLE I_T_VAR_RANGE INTO LOC_VAR_RANGE
           WITH KEY VNAM = 'ZSIGPERPI'.
          IF LOC_VAR_RANGE-LOW+4(3) = '001'.
            LOC_VAR_RANGE-LOW(4) = LOC_VAR_RANGE-LOW(4) - 1.
            LOC_VAR_RANGE-LOW+4(3) = '012'.
          ELSE.
            v_per3 = LOC_VAR_RANGE-LOW+4(3) - 1.
            LOC_VAR_RANGE-LOW+4(3) = v_per3.
          ENDIF.
          L_S_RANGE-HIGH = LOC_VAR_RANGE-LOW.
          L_S_RANGE-LOW  = '1000001'.
          L_S_RANGE-SIGN = 'I'.
          L_S_RANGE-OPT  = 'BT'.
          APPEND L_S_RANGE TO E_T_RANGE.
        ENDIF.
      WHEN 'ZSIGPERAN'.
        IF I_STEP = 2. "after the popup
          CLEAR L_S_RANGE.
          READ TABLE I_T_VAR_RANGE INTO LOC_VAR_RANGE
           WITH KEY VNAM = 'ZSIGPERPI'.
          L_S_RANGE-HIGH = LOC_VAR_RANGE-HIGH.
          L_S_RANGE-LOW  = '1000001'.
          L_S_RANGE-SIGN = 'I'.
          L_S_RANGE-OPT  = 'BT'.
          APPEND L_S_RANGE TO E_T_RANGE.
        ENDIF.
      WHEN 'ZSIGVDRPI'.
        IF I_STEP = 2. "after the popup
          CLEAR: L_S_RANGE,v_date,v_year,v_per3.
          READ TABLE I_T_VAR_RANGE INTO LOC_VAR_RANGE
           WITH KEY VNAM = 'ZSIGPERPI'.
          v_year = LOC_VAR_RANGE-HIGH(4).
          v_per3 = LOC_VAR_RANGE-HIGH+4(3).
          CALL FUNCTION 'LAST_DAY_IN_PERIOD_GET'
            EXPORTING
              I_GJAHR        = v_year
              I_MONMIT       = 00
              I_PERIV        = 'K4'
              I_POPER        = v_per3
            IMPORTING
              E_DATE         = v_date
            EXCEPTIONS
              INPUT_FALSE    = 1
              T009_NOTFOUND  = 2
              T009B_NOTFOUND = 3
              OTHERS         = 4.
          L_S_RANGE-LOW  = v_date.
          L_S_RANGE-SIGN = 'I'.
          L_S_RANGE-OPT  = 'EQ'.
          APPEND L_S_RANGE TO E_T_RANGE.
        ENDIF.
    Variables pour Production interne
    Intervalle
    Variables pour Production interne
    Intervalle
    WHEN 'ZSIGVDRPIM1'.
        IF I_STEP = 2. "after the popup
          CLEAR: L_S_RANGE,v_date,v_year,v_per3.
          READ TABLE I_T_VAR_RANGE INTO LOC_VAR_RANGE
           WITH KEY VNAM = 'ZSIGPERPI'.
          IF LOC_VAR_RANGE-LOW+4(3) = '001'.
            LOC_VAR_RANGE-LOW(4) = LOC_VAR_RANGE-LOW(4) - 1.
            LOC_VAR_RANGE-LOW+4(3) = '012'.
          ELSE.
            v_per3 = LOC_VAR_RANGE-LOW+4(3) - 1.
            LOC_VAR_RANGE-LOW+4(3) = v_per3.
          ENDIF.
          v_year = LOC_VAR_RANGE-LOW(4).
          v_per3 = LOC_VAR_RANGE-LOW+4(3).
          CALL FUNCTION 'LAST_DAY_IN_PERIOD_GET'
            EXPORTING
              I_GJAHR        = v_year
              I_MONMIT       = 00
              I_PERIV        = 'K4'
              I_POPER        = v_per3
            IMPORTING
              E_DATE         = v_date
            EXCEPTIONS
              INPUT_FALSE    = 1
              T009_NOTFOUND  = 2
              T009B_NOTFOUND = 3
              OTHERS         = 4.
          L_S_RANGE-LOW  = v_date.
          L_S_RANGE-SIGN = 'I'.
          L_S_RANGE-OPT  = 'EQ'.
          APPEND L_S_RANGE TO E_T_RANGE.
        ENDIF.
    Variables pour Production interne
    Intervalle
    Edited by: Yass79 on Jan 9, 2012 8:55 PM

    Hi ricx,
    hmm, Finally I got you...
    What you are asking is;
    Is it possible to have User exit for Custom Developed ABAP Programs?
    Am i right?
    If this is your question, i can say it is not needed as we can edit Zprograms whenever we need.
    If you have more doubts, revert back....
    Regards
    Karthik D

  • User Exit for CO11N to populate the Ref Order in Prod Order when Rework Ord

    HI All,
    I created a Production Order(100023) using TCode CO01 with 10 Qty.
    When i am creating a Production Order confirmation using TCode CO11N, i Confirmed 9 Qty and 1 Qty for Rework Order, it is confirming the 9Qty and creating a new Production Order (100024) for 1Qty.
    As per the requirement it is working fine. While system creating a Production Order (100024) for the Rework Qty, i need to populate the Reference Production Order number (100023) in the field Ref. Order in Control Data tab in the Production Order.
    Can any one suggest me how to populate this field? Is this possible by any USER EXIT or BADI ?
    Or Can we do it by configuration?
    Regards,

    Hey all: I already have solved it. This was solved using a batch input application: before is launched the MIGO transaction, we print the smartorm using ME38 transaction with SHDB.

Maybe you are looking for