11 Enhancements & Modifications.pptx

604 views 33 slides Feb 29, 2024
Slide 1
Slide 1 of 33
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33

About This Presentation

Enhacements


Slide Content

1 Enhancements & Modifications

2 Introduction Enhancements - We enhance the SAP functionalities in customer namespace (name should start with Z or Y). Modifications - We enhance the SAP functionalities in SAP namespace(name should not start with Z or Y).

3 Types of Enhancements and Modifications The various types of enhancements and modifications are as follows: Implicit and Explicit enhancements - Enhancement Customer Exit - Enhancement BADI (Business Addin’s) - Enhancement User Exit - Modification

4 Implicit Enhancements In case of implicit enhancements, implicit point is available at the starting or at the last of the program, sub routines, function modules etc. We create the implicit implementation using these implicit points.

5 Explicit Enhancements In case of explicit enhancements, enhancement-point and enhancement-section are available at any line. We create the explicit implementation using these enhancement-point and enhancement-section. Enhancement spot is the container for the enhancement-point and enhancement-section.

6 Enhancement-Point and Enhancement-Section Comparison Enhancement-Point does not have default implementation whereas Enhancement-Section has default implementation. With the help of Enhancement-Point we can only add additional codes, we cannot replace the existing code whereas with the help of Enhancement-Section we can change or replace the existing code.

7 Customer Exit Customer exit is an enhancement. We enhance the SAP functionalities in customer namespace. There are 3 types of customer exit. Function Module exit/Function exit Menu exit Screen exit

8 Function Module Exit The function module exit allows us to add our code to the SAP programs with the help of function modules. Syntax : CALL CUSTOMER-FUNCTION 'three digit number’. The three digit number in the above syntax varies from 000 to 999. Example : CALL CUSTOMER-FUNCTION ‘001’.

9 Ways to Find a Function Module Exit Put the break-point on the statement CALL CUSTOMER-FUNCTION. Pass the package name of the program in SMOD transaction code. (Utilities-Find-Package) Pass the package name of the program in SE84 transaction code. (Enhancements-Customer Exits-Enhancements-Package)

10 Steps to Implement a Function Module Exit Go to transaction code - CMOD Provide a project name and click create. Click on enhancement assignment tab and provide the customer exit name. Click on components tab - It shows the various function module exits available. Double click on to required function module exit which navigates to function module. Write the logic in the Z include of that function module. Activate the project.

11 Menu Exit Menu exit allows us to add menu items to the menu of SAP programs. These menu items have function codes that begin with "+" (a plus sign). We can perform customer specific functionalities on these menu items.

12 Ways to Find a Menu Exit Check for menu items starting with"+" (a plus sign) in the menu bar. (System-Status-GUI status-Menu Bar) Pass the package name of the program in SMOD transaction code. (Utilities-Find-Package) Pass the package name of the program in SE84 transaction code. (Enhancements-Customer Exits-Enhancements-Package)

13 Steps to Implement a Menu Exit Go to transaction code - CMOD Provide a project name and click create. Click on enhancement assignment tab and provide the customer exit name. Click on components tab - It shows the various menu exits available. Double click on to required menu exit. Provide the various information like - function text, icon, icon text and information text.

14 Steps to Implement a Menu Exit(Contd.) To write the code, we need to implement the required function module exit. Activate the project.

15 Screen Exit Screen exit allows us to add fields to the screen of SAP programs with the help of customer subscreen. SAP provides subscreen areas within a standard screen. The customer subscreen is called within the standard screen. Syntax to call customer subscreen in to standard screen: CALL CUSTOMER-SUBSCREEN <subscreen area> INCLUDING <program name> <customer subscreen number>. Example - CALL CUSTOMER-SUBSCREEN ‘custscr2’ INCLUDING ‘SAPLXT’ ‘2000’.

16 Ways to Find a Screen Exit Check in the screen flow logic for the statement CALL CUSTOMER-SUBSCREEN. Pass the package name of the program in SMOD transaction code. (Utilities-Find-Package) Pass the package name of the program in SE84 transaction code. (Enhancements-Customer Exits-Enhancements-Package)

17 Steps to Implement a Screen Exit Go to transaction code - CMOD Provide a project name and click create. Click on enhancement assignment tab and provide the customer exit name. Click on components tab - It shows the various screen exits available. Double click on the required screen exit. Create the screen and design the respective layout on the screen. Change the screen type to subscreen.

18 Steps to Implement a Screen Exit(Contd.) To write the code, we need to implement the required function module exit. Activate the project.

19 Important Points, Transaction Codes and Tables Imp point : One customer exit can only be assigned to one project at a time. SMOD - Transaction code to find a customer exit. CMOD - Transaction code to implement a customer exit. MODSAP - Table to find a customer exit. MODACT - Table to find a project for a customer exit.

20 BADI BADI is an enhancement. We enhance the SAP functionalities in customer namespace. The full form of BADI is Business ADD In's. It is based upon OOPS concepts (interfaces and classes). SE18 is the transaction code for BADI definition. SE19 is the transaction code for BADI implementation.

21 Types of BADI There are 2 types of BADI. Classic BADI. New BADI (Kernel BADI).

22 Ways to Find a Classic BADI We can use SAP class - CL_EXITHANDLER. In this class we have the method name - GET_INSTANCE. Pass the package name of the program in SE18 transaction code. (Click on F4 help of BADI Name-New Selection-Package). Pass the package name of the program in SE84 transaction code. (Enhancements-Business Addin’s-Definitions-Package).

23 Steps to Implement a Classic BADI Go to transaction code - SE19 Choose the radio button classic BADI, pass the name of BADI definition and click on create. Provide the BADI implementation name and description. Click on to interface tab, the name of implementing class automatically appears. Double click on the class and write the logic in the respective method. Activate the class and the BADI implementation.

24 Various Options of Classic BADI Multiple use - We can create multiple implementations. SAP internal - Only for SAP use.

25 Ways to Find a New(Kernel) BADI Put the break point on statement - CALL BADI or GET BADI. Pass the package name of the program in SE18 transaction code. (Click on F4 help of BADI Name-New Selection-Package). Pass the package name of the program in SE84 transaction code. (Enhancements-Business Addin’s-Definitions-Package).

26 Steps to Implement a New BADI Go to transaction code - SE19 Choose the radio button new BADI, pass the name of enhancement spot and click on create. Provide the enhancement implementation name and description. Provide the name of BADI implementation, implementing class and choose the respective BADI definition.

27 Steps to Implement a New BADI(Contd.) Double click on the class and write the logic in the respective method. Activate the class and the enhancement implementation.

28 Various Options of New BADI Multiple use - We can create multiple implementations. Can only be implemented internally at SAP - Only for SAP use.

29 Classic BADI and New BADI Comparison We find classic BADI by using the class CL_EXITHANDLER(method : GET_INSTANCE) whereas we find the new BADI by using the statements CALL BADI or GET BADI. In classic BADI, there is no enhancement spot whereas in new BADI, there is an enhancement spot. Enhancement spot is the container for the new BADI definition.

30 Classic BADI and New BADI Comparison(Contd.) In classic BADI, there is no enhancement implementation whereas in new BADI, there is an enhancement implementation. Enhancement implementation is the container for the new BADI implementation. In classic BADI, the name of the implementing class automatically appears whereas in new BADI, we need to provide the implementing class name.

31 User Exit User Exit are modifications. We enhance the SAP functionalities in SAP namespace. They are only available in SAP SD (Sales & distribution) module. They are available in the form of a subroutines. The most important user exits related to sales order are available in program MV45AFZZ.

32 Ways to Find a User Exit Check the documentation of the program. Search for statement - PERFORM USEREXIT. Search in package - VMOD.

33 Thank You