Implement BADI PT_GEN_REQ for program RPTARQEMAIL - ESS

Hi,
I was trying to implement this method with the idea to send, always, a mail to the HR responsible.
For that I've written the following code (example):
method IF_EX_PT_GEN_REQ~GET_ADMINS.
data:
admins_receivers TYPE ptreq_email_receivers_tab,
p_receivers_temp TYPE somlreci1 .
p_receivers_temp-receiver = 00000001.
p_receivers_temp-rec_type = 'P'.
append p_receivers_temp to admins_receivers.
endmethod.
The problem is that it is not being sent any e-mail.
Any idea what is missing?
Thanks!
Any idea where can I find an example?
Edited by: Pedro Taveira on Nov 29, 2010 6:52 PM

The problem was with the parameters...
It is solved

Similar Messages

  • Implement BADI CKMLAVR_SIM for AVR Cost Component.

    Hello All,
    I am trying to implement badi CKMLAVR_SIM.
    I am refering OSS note 896461.
    I populated :
    gw_ckmlhd-kalnr = '100524889'.
    gw_ckmlhd-bwkey = 'AB'.
    gw_ckmlkeph-kalnr = '100524889'.
    gw_ckmlkeph-bdatj = '2011'.
    gw_ckmlkeph-poper = '1'.
    gw_ckmlkeph-categ = 'AB'.
    gw_ckmlkeph-keart = 'H'.
    gw_ckmlkeph-mlcct = 'E'.
    gw_ckmlkeph-kkzst = 'X'.
    gw_ckmlkeph-curtp = '10'.
    gw_ckmlkeph-waers = 'ZAR'.
    gw_ckmlkeph-kst001 = '1000'.
    I think so i am missing something.
    Please suggest if anybody has initialize the actual value of cost component using badi CKMLAVR_SIM.
    Thanks,
    Ankit.

    Hi Experts,
    I am facing the same problem.
    Need your input on this..
    Thanks in Advance.
    Thanks,
    Ankit.

  • How to implement  BADI's for the below issue

    Hi All,
    The URL is being populated correctly (without any spaces) to the follow on document (PR/PO) created in R/3 after implementing code corrections in BBP (replacing space by ‘=’ as shown below).
    When sending the PO to supplier portal, the outbound IDOC segment does not get populated properly. The text format ‘=’ is again converted to space in ECC 6.0 which was not the case with 4.5B.
    This is an upgrade issue as the function module used to format text ‘FORMAT_TEXTLINES’ is completely different in ECC 6.0. The entire code of this function module in 4.5B has been commented in ECC 6.0 and new code has been implemented which splits the text and inserts spaces while formatting as shown below.
    This issue can be resolved by implementing a customer exit or a BADI which gets called after standard SAP populates the IDOC. It requires implementing custom code to remove the unwanted spaces inserted by standard SAP for text id F07. Hence after SAP completes its processing to populate the IDOC, the text would be processed further to remove unwanted spaces before actually sending the IDOC out from SAP R/3.
    Thus this upgrade issue resolution requires R/3 development
    1.     BADI Definition:  ME_MMPUR_EINM, Method: PROCESS_TEXT
    This option is preferable.
    2.     User exit: EXIT_SAPLEINM_002
    I need your help on how to write this code in the form of BADI's.where we write and how to implement. ASAP
    thanks,
    Sridhar

    Hi All,
    The URL is being populated correctly (without any spaces) to the follow on document (PR/PO) created in R/3 after implementing code corrections in BBP (replacing space by ‘=’ as shown below).
    When sending the PO to supplier portal, the outbound IDOC segment does not get populated properly. The text format ‘=’ is again converted to space in ECC 6.0 which was not the case with 4.5B.
    This is an upgrade issue as the function module used to format text ‘FORMAT_TEXTLINES’ is completely different in ECC 6.0. The entire code of this function module in 4.5B has been commented in ECC 6.0 and new code has been implemented which splits the text and inserts spaces while formatting as shown below.
    This issue can be resolved by implementing a customer exit or a BADI which gets called after standard SAP populates the IDOC. It requires implementing custom code to remove the unwanted spaces inserted by standard SAP for text id F07. Hence after SAP completes its processing to populate the IDOC, the text would be processed further to remove unwanted spaces before actually sending the IDOC out from SAP R/3.
    Thus this upgrade issue resolution requires R/3 development
    1.     BADI Definition:  ME_MMPUR_EINM, Method: PROCESS_TEXT
    This option is preferable.
    2.     User exit: EXIT_SAPLEINM_002
    I need your help on how to write this code in the form of BADI's.where we write and how to implement. ASAP
    thanks,
    Sridhar

  • Implementing BADI MD_ADD_COL_EZPS for MD04 custom column

    Hi there,
    I'm using BADI MD_ADD_COL_EZPS to display 3 new buttons and three new columns in MD04.
    For each line item that is displayed, the custom column is filled, after the button is hit -This works fine.
    My Question is:
    Is there any way to limit the value that is filled into the new column so that it only appears on the FIRST line item/row?
    (At the moment it is repeated all the way down the page - the new value is a material characteristic, so doesn't change, will always be the same for each line)
    I've looked at all the available structures/tables in the FILL_ADD_COLUMNS method of the BADI, and none seem suitable
    to determine the "first" row. (ie. something like the way SY-TABIX or SY-INDEX might be used)
    Any help appreciated.
    Thanks,
    David.

    Hi Shubhendu,
    in the method 'ACTIVATE_ADD_COLUMNS', you can set the flag EZ1_MODE to '1' to make the first column visible always. (it's been a while, but I think setting it to '2' makes it visible when the button is pressed.)
    Same applies to EZ2_MODE for second column, EZ3_MODE for third.
    look at the flags/parameters in this method, and also in FILL_ADD_COLUMNS, to fill the data.
    here you need to fill structure EMDEZX_USEX1 (for column 1) etc.
    The code is hit for each record displayed in MD04
    Hopefully this helps you.
    Regards,
    David

  • Implement BADI  MEGUI_LAYOUT  for ME52N in sap

    Hi All,
    Can I make the order field disabled basing on some conditions of cost centre using the BADI MEGUI_LAYOUT.
    If yes can anyone mention the way it should be done.
    Thanks in Advance

    Closed

  • How to approve Leave Request for Workflow in ESS?

    Hey! Experts,
    Currently, I am working on ESS Leave Request Workflow referening the Standard Workflow Template WS12300111. The requirements are as such, requested leave need to be approved using TS 12300007 'Approve Process'. Here, I have created a customized Rule to get the actual agent since the requirement is like i have to check if the employee who is apply for leave on the date is present in any project (alternative C-project Org. Structure is maintained) than his / her project manager will be the approver else i need to get the approver from the central HR Org. Struct. For simplicity consider the employee is currently present in only one project.
    Also, for information the Rule is working fine. That is the workitem is received in the appropriate agent UWL.
    Now my doubt is, there is no approve  / reject button coming in the workitem in UWL
    Also, after refering documentation on help.sap.com i came to know that some reports need to be run in background for approval to be done.
    Here, I am confused and I am stucked as I dont know which reports need to be run and how will the approval will be done in MSS.
    Kindly, give me some guidance on the same so that i can proceed.
    Thnx! in advance.
    And yeah points will be rewarded on giving suitable answer for this.
    Regards,
    Mistry Wasim

    Hi,
    Following are the some important points you should understand about ESS Leave Request Workflow
    1. The Visualization ( how should it appear in UWL and what should happen when you click on a particular workitem) is defined in SWFVISU. Check for TS12300097. Generally, it invokes com.sap.xss.hr.lea.appl/LeaveRequestApprover Java WebDynpro application. Just check whether you are able to get the correct Leave Processing application called when you execute your workitem from UWL?
    2. In general it should have option to process the leave request either approve/reject. When the leave request gets approved/rejected the status of the Leave Request document gets changed ( in workflow it is &REQ.STATUS&
    3. There is a need to schedule a background job for program RPTARQPOST which will pick up all the documents in APPROVED status and creates an absence record for the same.
    4. Apart from schedule job as mentioned above, you also have to schedule a background job for program  RPTARQEMAIL, which is basically used to send e-mails for all the documents which are yet to be approved to correct manager.
    as you say , you can not see Approve/Reject options from UWL, it looks to me that correct javawebdynpro application is not being called for this task. Just check this !!
    Good Luck !!
    Regards
    Krishna Mohan

  • Implementing BADI BDCP_BEFORE_WRITE

    Dear Experts,
    I have implemented BADI BDCP_BEFORE_WRITE for a message type /SAPSLL/CREMAS_SLL.
    I have also added code to the method FILTER_BDCPV_BEFORE_WRITE.
    I have also placed a break point inside the implmented method. But at runtime I am unable to stop at the break point.
    At runtime I found that the class name associated to BADI at run time was found to be CL_EXM_IM_BDCP_BEFORE_WRITE(example class) and not ZCL_IM__BDCP_BEFORE_WRITE which I have used to implement.
    Also, the update debugger is on.
    Why does the system not halt at the breakpoint inside the implemented method?
    Regards,
    Jiten

    Hi Nabheet,
    Thanks for your reply.
    Yes. There is only one active BADI for a particular filter condition. Actually the change pointer was not activated for the required message type(which was also filter condition) and hence I was having the problem.
    After activating the change pointers I am now able to halt at the breakpoint in the required method.
    Thanks,
    Jiten

  • Implementing BADI for PO

    Dear All,
    <b>In the PO creation badi, in create/change/save methods, i need to clear the purchase info record defaulted by SAP.
    Also in create method, PO price needs to be defaulted as the same as PR price, if the reference PR is found. User should be able to change this default price and save the PO.</b>  Hence, I have to restrict this logic only to create method.
    Now i am trying to implement BADI for PO def (ME_PROCESS_PO_CUST) with (impl name: ZMM_POCREATE). For clearing the purchase info record i put the code in 2 different methods
    1. PROCESS_ITEM
      DATA: ls_mepoitem TYPE mepoitem.
      break LAKSHMIS.
    Get the PO item Details
      ls_mepoitem = im_item->get_data( ).
      ls_mepoitem-INFNR = space.
    Set the item data
      CALL METHOD im_item->set_data
        EXPORTING
          im_data = ls_mepoitem.
    2. OPEN
      DATA:
      ls_header   TYPE mepoheader,
      ls_mepoitem TYPE mepoitem.
      break lakshmis.
      CALL METHOD im_header->get_data
        RECEIVING
          re_data = ls_header.
    Get the items for the PO using get items method and change the purch info record to SPACE and set the values using SET_DATA on item.
    <b>However, in both the cases the value doesnot get changed (as i dont see any changing parameters provided). However the documentation of BADI says that we can change the HEADER as well as ITEM information in this BADI.</b>
    Can anyone please suggest, where i am going wrong and what needs to be done in order to achieve the above two requirements.
    Thanks in advance.
    Regards,
    Lakshmi

    BADI
    http://www.esnips.com/doc/e06e4171-29df-462f-b857-54fac19a9d8e/ppt-on-badis.ppt
    http://www.esnips.com/doc/10016c34-55a7-4b13-8f5f-bf720422d265/BADIs.pdf
    http://www.esnips.com/doc/43a58f51-5d92-4213-913a-de05e9faac0d/Business-Addin.doc
    http://www.esnips.com/doc/1e10392e-64d8-4181-b2a5-5f04d8f87839/badi.doc
    www.sapgenie.com/publications/saptips/022006%20-%20Zaidi%20BADI.pdf
    http://www.sapdevelopment.co.uk/enhance/enhance_badi.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/04/f3683c05ea4464e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/e6/d54d3c596f0b26e10000000a11402f/content.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/c2/eab541c5b63031e10000000a155106/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/04/f3683c05ea4464e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/e6/63ee7f486cc143a560799d8803ce29/content.htm
    https://www.sdn.sap.com/irj/sdn/wiki?path=/display/srm/badi-general+information&
    http://www.esnips.com/doc/e06e4171-29df-462f-b857-54fac19a9d8e/ppt-on-badis.ppt
    http://www.esnips.com/doc/10016c34-55a7-4b13-8f5f-bf720422d265/BADIs.pdf
    http://www.esnips.com/doc/43a58f51-5d92-4213-913a-de05e9faac0d/Business-Addin.doc
    http://www.esnips.com/doc/1e10392e-64d8-4181-b2a5-5f04d8f87839/badi.doc
    www.sapgenie.com/publications/saptips/022006%20-%20Zaidi%20BADI.pdf
    http://www.sapdevelopment.co.uk/enhance/enhance_badi.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/04/f3683c05ea4464e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/e6/d54d3c596f0b26e10000000a11402f/content.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/c2/eab541c5b63031e10000000a155106/frameset.htm
    The specified item was not found.
    http://help.sap.com/saphelp_erp2005/helpdata/en/73/7e7941601b1d09e10000000a155106/frameset.htm
    http://support.sas.com/rnd/papers/sugi30/SAP.ppt
    http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/abapindx.htm
    http://members.aol.com/_ht_a/skarkada/sap/
    http://www.ct-software.com/reportpool_frame.htm
    http://www.saphelp.com/SAP_Technical.htm
    http://www.kabai.com/abaps/q.htm
    http://www.guidancetech.com/people/holland/sap/abap/
    http://www.planetsap.com/download_abap_programs.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/c8/1975cc43b111d1896f0000e8322d00/content.htm
    http://www.allsaplinks.com/badi.html
    /people/thomas.weiss/blog/2006/04/03/how-to-define-a-new-badi-within-the-enhancement-framework--part-3-of-the-serieshttps [original link is broken]:///people/alwin.vandeput2/blog/2006/04/13/how-to-search-for-badis-trace-it
    /people/thomas.weiss/blog/2006/04/18/how-to-implement-a-badi-and-how-to-use-a-filter--part-4-of-the-series-on-the-new-enhancement-framework /people/thomas.weiss/blog/2006/05/03/source-code-enhancements--part-5-of-the-series-on-the-new-enhancement-framework
    http://www.esnips.com/doc/e06e4171-29df-462f-b857-54fac19a9d8e/ppt-on-badis.ppt
    http://www.esnips.com/doc/10016c34-55a7-4b13-8f5f-bf720422d265/BADIs.pdf
    http://www.esnips.com/doc/43a58f51-5d92-4213-913a-de05e9faac0d/Business-Addin.doc
    http://www.esnips.com/doc/1e10392e-64d8-4181-b2a5-5f04d8f87839/badi.doc
    http://www.esnips.com/doc/3b7bbc09-c095-45a0-9e89-91f2f86ee8e9/BADI-Introduction.ppt
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/40921dd7-d5cf-2910-1894-bb62316afbd1
    http://help.sap.com/saphelp_erp2005/helpdata/en/73/7e7941601b1d09e10000000a155106/frameset.htm
    http://support.sas.com/rnd/papers/sugi30/SAP.ppt
    http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/abapindx.htm
    http://members.aol.com/_ht_a/skarkada/sap/
    http://www.ct-software.com/reportpool_frame.htm
    http://www.saphelp.com/SAP_Technical.htm
    http://www.kabai.com/abaps/q.htm
    http://www.guidancetech.com/people/holland/sap/abap/
    http://www.planetsap.com/download_abap_programs.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/c8/1975cc43b111d1896f0000e8322d00/content.htm
    /people/thomas.weiss/blog/2006/04/03/how-to-define-a-new-badi-within-the-enhancement-framework--part-3-of-the-series
    /people/thomas.weiss/blog/2006/04/18/how-to-implement-a-badi-and-how-to-use-a-filter--part-4-of-the-series-on-the-new-enhancement-framework
    http://esnips.com/doc/e06e4171-29df-462f-b857-54fac19a9d8e/ppt-on-badis.ppt
    http://esnips.com/doc/43a58f51-5d92-4213-913a-de05e9faac0d/Business-Addin.doc
    http://esnips.com/doc/10016c34-55a7-4b13-8f5f-bf720422d265/BADIs.pdf
    http://esnips.com/doc/1e10392e-64d8-4181-b2a5-5f04d8f87839/badi.doc
    http://esnips.com/doc/365d4c4d-9fcb-4189-85fd-866b7bf25257/customer-exits--badi.zip
    http://esnips.com/doc/3b7bbc09-c095-45a0-9e89-91f2f86ee8e9/BADI-Introduction.ppt
    http://help.sap.com//saphelp_470/helpdata/EN/eb/3e7cee940e11d295df0000e82de14a/frameset.htm
    Rewards if useful.........
    Minal

  • Userexit or BADI for program *RMMRP000* for background job

    Hi,
    We are scheduling background job for MRP through SM36 using program  RMMRP000 or Through Transaction MDBT (MDBT is calling program RMMRP000) which creates PR (through background job).
    I want to default one field in PR (PO Price field in valuation tab in PR default to gross) using any userexit or BADI.
    Can any body suggest me userexit or BADI for program RMMRP000 for background job
    Regards.

    Hi,
    1. The below are the List of  Userexit for this MDBT t.CODE.
    2. But i dont see any one helping to resolve your issue.
    3. May be you should lookg at the Userexit for me21n or relevant Purhcase requisition creation transaction.
    reg
    dsk

  • Practical example for implementing BADI

    Hi all,
    Can anybody give me a link or documentatiom for implementing BADI with an example not theoritical practical.
    with regards,
    chandu.

    hi this thread will explain u the badi implementation related to purchase order...
    ME21N - PO Enhancement using BADI
    Just go thru that to get some idea on badi enhancement
    SAP help on BADI enhancement with sample badi
    http://help.sap.com/saphelp_nw04/helpdata/en/3e/0e1089c24611d1ad09080009b0fb56/frameset.htm
    regards
    gv
    Message was edited by: Venkat

  • Implement badi for vms isolate action

    Dear expert,
      I am developing the VMS(vehicle management system) action which is set as "isolate" action.
      I use badi for isolate action to perform execution logic (like update ztable and populate some value to VMS table).
      but the problem is, the history of vehicle, status of vehicle and green light at navigation pannel is not updated even the message display successful.
      Do I need to put some FM call after execute logic within this isolate badi?
      Can some give me some sample?
       Thank a lot.
    Regards,
    Boonsom

    Hi Tim,
    You can execute a method call in Action definition.
    This method call is a badi implementation.
    Badi: EXEC_METHODCALL_PPF
    In this method call you can trigger your external interface.
    Steps:
    1) Implement badi EXEC_METHODCALL_PPF to create you method implementation from which you will trigger your external interface
    2) Create an action definition in Action profile, in third level configuration for action profile, specifiy Method Call and assign the badi implemented method here.
    3) Schedule the action condition.
    Thats all.
    Test the Scenario.
    Best Regards,
    Pratik Patel
    <b>Reward with Points!</b>

  • Implementation Of Badi ME_GUI_PO_CUST for adding fields in Purchase Order

    Hi All
       I am implementing BADI ME_GUI_PO_CUST / ME_PROCESS_PO_CUST to add additional fields in Purchase Order.
    The implementation of the BADI ie the Subscreen of the fields to be added appears in  transaction ME23N but it does not appear in the transaction ME22N and ME21N.
    Can anyone help me on this.
    Thanx.
    Moderator message - Duplicate post locked
    Edited by: Rob Burbank on Jul 10, 2009 12:10 PM

    check the answer
    [New tabs added by Badi ME_GUI_PO_CUST not seen in ME21N and ME22N;
    bye

  • BADI - PT_GEN_REQ

    Hi,
    I want to change leave request approver in ESS portal base on our customized relationship in OM. I found that BADI 'PT_GEN_REQ', method 'FIND_RESP_AND_DEFAULT_NEXT_PRC' is the suitable interface to implement this.
    But I don't know how to start the coding, should I remove all the remarked standrard code in the original method? Anyone can show me some sample code?
    Thank you.
    Regards,
    Eric

    Hi Eric,
    Can you please give us your coding as a example? I have the same requirement as you but currently I get a dump due to the export parameter EX_DEF_NEXT_PROC_ACTOR, which does have the type TYPE REF TO IF_PT_REQ_A_WF. Something is wrong with this interface implementation - but what?!
    Thank you verym much for your help!!
    Regards
    Michael

  • Problem on Implementing badi ME_GUI_PO_CUST

    Hi Expert,
    I have implement BADI ME_GUI_PO_CUST, to add the new tab.
    I have managed to View the tab in Both ME21N, and ME22N with implement SUBSCRIBE and MAP_DYNPRO_FIELDS.
    method IF_EX_ME_GUI_PO_CUST~SUBSCRIBE
      DATA: ls_subscriber LIKE LINE OF re_subscribers.
      CHECK im_application = 'PO'.
      CHECK im_element = 'ITEM'.
      CLEAR re_subscribers[].
      ls_subscriber-name = subscreen1.
      ls_subscriber-dynpro = '0002'.
      ls_subscriber-program = 'ZRPP_ME_GUI_PO_CUST_SCREEN'.
      ls_subscriber-struct_name = 'CI_EKPODB'.
      ls_subscriber-label = text-001.
      ls_subscriber-position = 7.
      ls_subscriber-height = 7.
      APPEND ls_subscriber TO re_subscribers.
    METHOD : IF_EX_ME_GUI_PO_CUST~MAP_DYNPRO_FIELDS
      FIELD-SYMBOLS: <mapping> LIKE LINE OF ch_mapping.
      LOOP AT ch_mapping ASSIGNING <mapping>.
        CASE <mapping>-fieldname.
          WHEN 'ZCNUM'.      <mapping>-metafield = mmmfd_cust_01.
        ENDCASE.
      ENDLOOP.
    Method IF_EX_ME_GUI_PO_CUST~MAP_DYNPRO_FIELDS
      DATA: lw_fieldselection LIKE LINE OF ch_fieldselection.
      LOOP AT ch_fieldselection INTO lw_fieldselection.
        lw_fieldselection-fieldstatus = '+'.
        MODIFY ch_fieldselection FROM lw_fieldselection.
      ENDLOOP.
    I need to store the value, and some of thread said it required methods:
    TRANSPORT_FROM_MODEL
    TRANSPORT_TO_DYNP
    TRANSPORT_FROM_DYNP
    TRANSPORT_TO_MODEL
    I have click on the subcreen, or enter at the field, but it will not able to trigger the Above Methods.
    How do I do for the to trigger above Methods? Or Should I added some additional code at screen program? I want SAVE the data actually into EKPO.
    Thanks in advance.

    Hi Sim,
    Recently we have the same reqirement.
    You can have a look at the below code..
    First method: SUBSCRIBE  
    DATA: ls_subscriber LIKE LINE OF re_subscribers.* we want to add a customer subscreen on the Header tab
        CHECK im_application = 'PO'.
        CHECK im_element     = 'HEADER'.* each line in re_subscribers generates a subscreen. We add one subscreen in this example
        CLEAR re_subscribers[].
    * the name is a unique identifier for the subscreen and defined in this class definition
        ls_subscriber-name = subscreen1.
    * the dynpro number to use
        ls_subscriber-dynpro = '0001'.
    * the program where the dynpro can be found
        ls_subscriber-program = 'SAPLZKMMM_KAU86037'.
    * each subscreen needs his own DDIC-Structure
        ls_subscriber-struct_name = 'CI_EKKODB'.
    * a label can be defined
        ls_subscriber-label = text-001.
    * the position within the tabstrib can be defined
        ls_subscriber-position = 13.
    * the height of the screen can be defined here. Currently we suport two screen sizes:
    * value <= 7 a sevel line subscreen
    * value > 7  a 16 line subscreen
        ls_subscriber-height = 7.    APPEND ls_subscriber TO re_subscribers.Here, parameter u2018im_elementu2019 is defined as u2018HEADERu2019 as we are adding new tab in header section of PO.  
    Define a function group and take the main program and define it in ls_subscriber-program.
    Also define a sub screen with the required fields and assign it to the parameter ls_subscriber-dynpro.  
    Then method MAP_DYNPRO_FIELDS  
    FIELD-SYMBOLS: <mapping> LIKE LINE OF ch_mapping.
        LOOP AT ch_mapping ASSIGNING <mapping>.    CASE <mapping>-fieldname.      WHEN 'ZZPAYMENT_AGRE'.      <mapping>-metafield = mmmfd_cust_03.
          WHEN 'ZZPROJECT'.                     <mapping>-metafield = mmmfd_cust_04.
        ENDCASE.  ENDLOOP.  TRANSPORT_FROM_MODEL:
    DATA:     l_header       TYPE REF TO if_purchase_order_mm,
                  ls_mepoheader  TYPE mepoheader,
                  ls_customer    TYPE CI_EKKODB.*--------------------------------------------------------------------*
    * system asks to transport data from the business logic into the view
    *--------------------------------------------------------------------*    CASE im_name.      WHEN subscreen1.* is it an Header? im_model can be header or item.
            mmpur_dynamic_cast l_header im_model.
            CHECK NOT l_header IS INITIAL.* transport standard fields
            ls_mepoheader = l_header->get_data( ).* store info for later use
            MOVE-CORRESPONDING ls_mepoheader TO dynp_data_pbo.
          WHEN OTHERS.
        ENDCASE.    TRANSPORT_TO_DYNP:
    Define a FM 'ZK_KAU86037_PUSH' to push the values.CASE im_name.      WHEN subscreen1.        CALL FUNCTION 'ZK_KAU86037_PUSH'
              EXPORTING
                im_dynp_data = dynp_data_pbo.      WHEN OTHERS.
        ENDCASE.    TRANSPORT_FROM_DYNP:
      Define another FM 'ZK_KAU86037_POP'.CASE im_name.      WHEN subscreen1.        CALL FUNCTION 'ZK_KAU86037_POP'
              IMPORTING
                ex_dynp_data = dynp_data_pai.        IF dynp_data_pai NE dynp_data_pbo.
    * something has changed therefore we have to notify the framework
    * to transport data to the model
              re_changed = mmpur_yes.
            ENDIF.      WHEN OTHERS.
        ENDCASE.  TRANSPORT_TO_MODEL:     
            DATA: l_header             TYPE REF TO if_purchase_order_mm,
              ls_mepoheader        TYPE mepoheader,
              ls_customer          TYPE CI_EKKODB,
              l_po_header_handle   TYPE REF TO cl_po_header_handle_mm.*--------------------------------------------------------------------*
    * data have to be transported to business logic
    *--------------------------------------------------------------------*    CASE im_name.      WHEN subscreen1.* is it an item? im_model can be header or item.
            mmpur_dynamic_cast l_header im_model.
            CHECK NOT l_header IS INITIAL.        ls_mepoheader = l_header->get_data( ).* standard fields changed?
            IF dynp_data_pbo-zzpayment_agre   NE dynp_data_pai-zzpayment_agre
            OR dynp_data_pbo-zzproject        NE dynp_data_pai-zzproject.* update standard fields
              ls_mepoheader-zzpayment_agre   = dynp_data_pai-zzpayment_agre.
              ls_mepoheader-zzproject  = dynp_data_pai-zzproject.
              CALL METHOD l_header->set_data
                EXPORTING
                  im_data = ls_mepoheader.
            ENDIF.
          WHEN OTHERS.    ENDCASE. 
    Then we have to implement one more BADI to display the tab and update the values.
    Implement the BADI ME_PROCESS_PO_CUST. This cannot be used multiple times.  
    In this, we have methods (PROCESS_HEADER,PROCESS_ITEM).if we need to any validations for the fields we can write the logic here in this methods. In my case I need to check for the document type which I implemented in the method (PROCESS_HEADER).  
    Hope it helps you.
    Thanks
    Arbind

  • Need Ways to implement Badis in ECC 6.0 (Enhancement Points)

    Hi experts,
    I am new to BADIs. I've a requirement to find a BADI for changing Customer number while posting customer invoice in SAP (the data is coming from XI system in IDOC format). I want to know any BADIs or userexits are there for my requirement. At the same time I want to know how to implement a BADI in ECC 6.0 .Any docs releated to this topic will be of great help.
    points will be awarded for sure..........

    hi Poorna Chandras... ,
    These steps should enable you to find any BADI related to any transaction in a matter of minutes.
    Procedure 1:
    1) Go to the transaction SE37 to find your function module.
    2) Locate the function SXV_GET_CLIF_BY_NAME.
    3) Put a breakpoint there.
    4) Now open a new session.
    5) Go to your transaction. 6) At that time, it will stop this function.
    7) Double click on the function field EXIT_NAME.
    8) That will give you name of the BADI that is provided in your transaction.
    Business Add-Ins
    Procedure 2:
    1) Goto se24 (Display class cl_exithandler)
    2) Double click on the method GET_INSTANCE.
    3) Put a break point at Line no.25 (CASE sy-subrc).
    4) Now Execute SAP standard transaction
    5) Press the required button for which you need to write an exit logic, the execution will stop at the break point.
    6) Check the values of variable 'exit_name', it will give you the BADI name called at that time.
    7) This way you will find all the BADIs called on click of any button in any transaction
    SAP Business Add-Ins (BAdIs) are one of the most important technologies used to adapt SAP software to specific requirements. BAdIs were introduced with Release 4.6 and replace function module exits. This technology is not limited to SAP applications. BAdI calls can be integrated in customer applications. These can then be enhanced by other customer applications. In the various SAP applications, BAdI calls are implemented at places where enhancements are appropriate.Business add-ins are enhancements to the standard version of the system. They can be inserted into the SAP System to accommodate user requirements too specific to be included in the standard delivery. Since specific industries often require special functions, SAP allows you to predefine these points in your software.
    In contrast to customer exits, Business Add-Ins no longer assume a two-level infrastructure (SAP and customer solutions), but instead allow for a multi-level system landscape (SAP, country-specific versions, industry solutions, partner, customer, and so on). You can create definitions and implementations of Business Add-Ins at any level of the system landscape.SAP guarantees the upward compatibility of all Business Add-In interfaces. Release upgrades do not affect enhancement calls from within the standard software nor do they affect the validity of call interfaces. You do not have to register Business Add-Ins in SSCR.
    The Business Add-In enhancement technique differentiates between enhancements that can only be implemented once and enhancements that can be used actively by any number of customers at the same time. In addition, Business Add-Ins can be defined according to filter values. This allows you to differentiate between Add-In implementations using the filter Country or other criteria.
    The enhancement technique is set up in such a way that it is possible to define interfaces for ABAP soure code, screens, GUI interfaces, and tables. These allow customers to include their own enhancements in the standard. A single Business Add-In contains all of the interfaces necessary to implement a specific task.
    BADI is just an object-oriented version of user-exit. Instead of entering program code into some function module (as in customer-exit), you define some class which has to implement predefined methods and those methods are fired at predefined points just like an old user-exit. Some BADI can have multiple independent implementations which is much better for software deployment as several developers can implement the same BADI independently. BADI/UserExists are used to enhance R/3 For customer Needs.
    Actually there is no transaction to find when and where the BADI
    is called.
    1. You can see the BADI description to find why it is called.
    2. Once you implemented and activated the BADI, put some break points
    in the BADI and see "where else used" option to check in what all
    programs this BADI is called. In the ITS debug, when you are doing
    the operation what exactly the BADI description tells, it will take
    to the break points and you have to do manually debug the whole thing.
    I know its bit difficult to do manual debug the whole thing, it
    takes lot of time, but you have to be very patience when you are
    dealing with BADI's.
    Transaction SE18 is the BADI equivalent of transaction SMOD
    Transaction SE19 is the BADI equivalent of transaction CMOD .
    To find the BADI to be implemented and then implement this via SE19.
    Check this blogs 2 find a BADI:
    How to find if we have a BADI in Transaction VB02
    Re: BADI for screen enhancement in MM01  transaction
    Re: BADI and User exits
    How To Define a New BAdI Within the Enhancement Framework (Some Basics About the BAdI,BAdI Commands in ABAP,
    When to Use a BAdI?)
    /people/thomas.weiss/blog/2006/04/03/how-to-define-a-new-badi-within-the-enhancement-framework--part-3-of-the-series
    How to implement a BAdI And How to Use a Filter
    /people/thomas.weiss/blog/2006/04/18/how-to-implement-a-badi-and-how-to-use-a-filter--part-4-of-the-series-on-the-new-enhancement-framework
    Introducing Business Add-Ins
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f3202186-0601-0010-6591-b832b1a0d0de
    How to implement BAdi in Enhancement Framework
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/d0456c54-0901-0010-f0b3-cd765fb99702
    Business Add-Ins
    http://help.sap.com/saphelp_47x200/helpdata/en/ee/a1d548892b11d295d60000e82de14a/frameset.htm
    BAdI: Customer-Defined Functions in the Formula Builder
    http://help.sap.com/saphelp_nw04/helpdata/en/04/f3683c05ea4464e10000000a114084/content.htm
    Difference Between BADI and User Exits
    http://www.sap-img.com/abap/difference-between-badi-and-user-exits.htm
    To Use BADI - Business Add In you need to Understand ABAP OO Interface Concept
    http://www.sap-img.com/abap/business-add-in-you-need-to-understand-abap-oo-interface-concept.htm
    You can check the links for Step by Step Badi Implemntation
    (very helpful self learning docs).
    BADI Step by Step Implementation.
    http://www.esnips.com/doc/e06e4171-29df-462f-b857-54fac19a9d8e/ppt-on-badis.ppt
    http://www.esnips.com/doc/10016c34-55a7-4b13-8f5f-bf720422d265/BADIs.pdf
    http://www.esnips.com/doc/43a58f51-5d92-4213-913a-de05e9faac0d/Business-Addin.doc
    http://www.esnips.com/doc/1e10392e-64d8-4181-b2a5-5f04d8f87839/badi.doc
    www.sapgenie.com/publications/saptips/022006%20-%20Zaidi%20BADI.pdf
    http://www.sapdevelopment.co.uk/enhance/enhance_badi.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/04/f3683c05ea4464e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/e6/d54d3c596f0b26e10000000a11402f/content.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/c2/eab541c5b63031e10000000a155106/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/04/f3683c05ea4464e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/e6/63ee7f486cc143a560799d8803ce29/content.htm
    https://www.sdn.sap.com/irj/sdn/wiki?path=/display/srm/badi-general+information&
    http://www.esnips.com/doc/e06e4171-29df-462f-b857-54fac19a9d8e/ppt-on-badis.ppt
    http://www.esnips.com/doc/10016c34-55a7-4b13-8f5f-bf720422d265/BADIs.pdf
    http://www.esnips.com/doc/43a58f51-5d92-4213-913a-de05e9faac0d/Business-Addin.doc
    http://www.esnips.com/doc/1e10392e-64d8-4181-b2a5-5f04d8f87839/badi.doc
    www.sapgenie.com/publications/saptips/022006%20-%20Zaidi%20BADI.pdf
    http://www.sapdevelopment.co.uk/enhance/enhance_badi.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/04/f3683c05ea4464e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/e6/d54d3c596f0b26e10000000a11402f/content.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/c2/eab541c5b63031e10000000a155106/frameset.htm
    The specified item was not found.
    http://help.sap.com/saphelp_erp2005/helpdata/en/73/7e7941601b1d09e10000000a155106/frameset.htm
    http://support.sas.com/rnd/papers/sugi30/SAP.ppt
    http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/abapindx.htm
    http://members.aol.com/_ht_a/skarkada/sap/
    http://www.ct-software.com/reportpool_frame.htm
    http://www.saphelp.com/SAP_Technical.htm
    http://www.kabai.com/abaps/q.htm
    http://www.guidancetech.com/people/holland/sap/abap/
    http://www.planetsap.com/download_abap_programs.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/c8/1975cc43b111d1896f0000e8322d00/content.htm
    http://www.allsaplinks.com/badi.html
    /people/thomas.weiss/blog/2006/04/03/how-to-define-a-new-badi-within-the-enhancement-framework--part-3-of-the-serieshttps:///people/alwin.vandeput2/blog/2006/04/13/how-to-search-for-badis-trace-it
    /people/thomas.weiss/blog/2006/04/18/how-to-implement-a-badi-and-how-to-use-a-filter--part-4-of-the-series-on-the-new-enhancement-framework /people/thomas.weiss/blog/2006/05/03/source-code-enhancements--part-5-of-the-series-on-the-new-enhancement-framework
    http://www.esnips.com/doc/e06e4171-29df-462f-b857-54fac19a9d8e/ppt-on-badis.ppt
    http://www.esnips.com/doc/10016c34-55a7-4b13-8f5f-bf720422d265/BADIs.pdf
    http://www.esnips.com/doc/43a58f51-5d92-4213-913a-de05e9faac0d/Business-Addin.doc
    http://www.esnips.com/doc/1e10392e-64d8-4181-b2a5-5f04d8f87839/badi.doc
    http://www.esnips.com/doc/3b7bbc09-c095-45a0-9e89-91f2f86ee8e9/BADI-Introduction.ppt
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/40921dd7-d5cf-2910-1894-bb62316afbd1
    http://help.sap.com/saphelp_erp2005/helpdata/en/73/7e7941601b1d09e10000000a155106/frameset.htm
    http://support.sas.com/rnd/papers/sugi30/SAP.ppt
    http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/abapindx.htm
    http://members.aol.com/_ht_a/skarkada/sap/
    http://www.ct-software.com/reportpool_frame.htm
    http://www.saphelp.com/SAP_Technical.htm
    http://www.kabai.com/abaps/q.htm
    http://www.guidancetech.com/people/holland/sap/abap/
    http://www.planetsap.com/download_abap_programs.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/c8/1975cc43b111d1896f0000e8322d00/content.htm
    /people/thomas.weiss/blog/2006/04/03/how-to-define-a-new-badi-within-the-enhancement-framework--part-3-of-the-series
    /people/thomas.weiss/blog/2006/04/18/how-to-implement-a-badi-and-how-to-use-a-filter--part-4-of-the-series-on-the-new-enhancement-framework
    http://esnips.com/doc/e06e4171-29df-462f-b857-54fac19a9d8e/ppt-on-badis.ppt
    http://esnips.com/doc/43a58f51-5d92-4213-913a-de05e9faac0d/Business-Addin.doc
    http://esnips.com/doc/10016c34-55a7-4b13-8f5f-bf720422d265/BADIs.pdf
    http://esnips.com/doc/1e10392e-64d8-4181-b2a5-5f04d8f87839/badi.doc
    http://esnips.com/doc/365d4c4d-9fcb-4189-85fd-866b7bf25257/customer-exits--badi.zip
    http://esnips.com/doc/3b7bbc09-c095-45a0-9e89-91f2f86ee8e9/BADI-Introduction.ppt
    http://help.sap.com//saphelp_470/helpdata/EN/eb/3e7cee940e11d295df0000e82de14a/frameset.htm
    Difference Between BADI and User Exits
    http://www.sap-img.com/abap/difference-between-badi-and-user-exits.htm
    New to Badi`s
    New to BADI
    New to BADI long question
    Badi
    /message/4866901#4866901 [original link is broken]
    Hope this helps
    Rewards if useful.........
    Cheers
    Kripa Rangachari.

Maybe you are looking for

  • Help! My DW site displays in FireFox, but does not work in IE

    Help! My DW site displays fine in FireFox, but only the background loads in Internet Explorer and I get an error message that the site cannot open. The site is www.bransonareagolfcouncil.com

  • DPM agent installation through SCCM

    Hi, We have DPM 2012 installed and we want to install the DPM agent through SCCM to all client server, can you please tell me the process.. Appreciate if you can update at earliest.

  • Where is mfg date in iphone4?

    where is mfg date in iphone4? or how can i check mfg date in handset only

  • Repetative manufacturing vs discrete manufacturing?

    hi what is the difference between repetative manufacturing and discrete manufacturing                                                                                 regards                                                                             

  • ASAP Implementation using SOLMAN

    HI All, Can you please guide me if we can implement sap using ASAP methodology in SOLMAN? In other words can solman be a substitue for ASAP tools and download from CD?Or there is no substitute to ASAP software? Also guide me if solman can become a pa