07-03-2007 7:52 PM
I'm programming an example of BADI's following a tutorial but I have some questions.
1. In TCODE sucomp I found a BADI: ADDRESS_CHECK with ST05 tracking
2. I Create a Project ZPROJ and I need to know the name of the enhancement (in this case is: SZRS0003) how can I find this name?
3. Then in CMOD I go to Components and I can se de FM with a Z INCLUDE. In this include I can write custom code.
Another question... I've read that you can use a badi more than one time (not like user-exits) but if I create a new project and I want to assign the same enhancement: SZRS0003 I receive an error... because the enhancement is already in use. what's happening?
Thanx in advanced
07-03-2007 8:18 PM
Hi,
Why are you writing your code in CMOD ? CMOD is used for Customer exits (FM exit, screen exits and menu exits) and not for BADI's.
You have to use transaction SE19 for implementing a BADI.
Please explain your problem in detail.
Reward points if the answer is helpful.
Regards,
Mukul
07-03-2007 8:21 PM
You should not use CMOD or SMOD ,
Goto transaction SE18. Enter the BADI name.
Click on Implementation option in Tool Bar. Create a new Implementation.
Click on the method available on it.
You can write your code in this method.
See below link for more info:
Goto transaction SE18. Enter the BADI name.
Click on Implementation option in Tool Bar. Create a new Implementation.
Click on the method available on it.
You can write your code in this method.
See below link for more info:
Step by step proc
http://www.sapdevelopment.co.uk/enhance/enhance_badi.htm
Also the foll links
http://help.sap.com/saphelp_nw2004s/helpdata/en/c5/03853c01c89d7ce10000000a11405a/frameset.htm
http://help.sap.com/saphelp_nw04/helpdata/en/5f/071eed117c11d5b37d0050dadef62b/content.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/e6/d54d3c596f0b26e10000000a11402f/frameset.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/eb/3e7cf4940e11d295df0000e82de14a/frameset.htm
http://www.sap-img.com/abap/business-add-in-you-need-to-understand-abap-oo-interface-concept.htm
http://www.sapdevelopment.co.uk/tcodes/tcodes.htm
infospoke with transformation with badi
http://help.sap.com/saphelp_nw04/helpdata/en/c5/03853c01c89d7ce10000000a11405a/content.htm
Thanks
Seshu
07-04-2007 4:37 AM
Hi
You need not create project for a badi,
Just go to transaction se19, create an implementation for the badi and code in the relevant methods.
Regards
Dinesh
07-04-2007 7:05 AM
Hi,
Implementing Business Add-Ins (BADI)
The use of object orientated code within SAP has lead to new method of enhancing standard SAP code called
Business Add-Ins or BADI's for short. Although the implementation concept is based on classes, methods and
inheritance you do not really have to understand this fully to implement a BADI. Simply think of methods
as a function module with the same import and export parameters and follow the simple instructions below.
Steps:
1. Execute Business Add-In(BADI) transaction SE18
2. Enter BADI name i.e. HRPBSGB_HESA_NISR and press the display
button
3. Select menu option Implementation->Create
4. Give implementation a name such as Z_HRPBSGB_HESA_NISR
5. You can now make any changes you require to the BADI within this
implementation, for example choose the Interface tab
6. Double click on the method you want to change, you can now enter
any code you require.
7. Please note to find out what import and export parameters a
method has got return the original BADI definition
(i.e. HRPBSGB_HESA_NISR) and double click on the method name
for example within HRPBSGB_HESA_NISR contract is a method
8. When changes have been made activate the implementation
See below link for more info:
Step by step proc
http://www.sapdevelopment.co.uk/enhance/enhance_badi.htm
<b>Reward points</b>
Regards
07-04-2007 9:49 AM
Hi,
To know the name of enhancement u have two ways:
1. Go for searching the component name e,g; package name,t code, program name in system->status and then search the the function "customer-function".
2. U can also search the same in se80 repository for same function name.
Yes it is true that multiple implementations are possible for BADIs but u cannot use the same definition again and again only u can change ur functionality for that definition and every time u have to deactivate the implementation before u go on for the modification for the same and after u finish changes again activate the project.
Pls reward points.
Regards,
Ameet