Adjusting the R/3
- Customizing: this means setting up specific business processes and functions for your system according to an implementation guide. The need for these changes has already been foreseen by SAP and an implementation procedure has been developed.
- Personalization: this means making changes to certain fields' global display attributes (setting default values or fading fields out altogether), as well as creating user-specific menu sequences.
- Modifications: these are changes to SAP repository objects made at the customer site. If SAP delivers a changed version of the object, the customer's system must be adjusted to reflect these changes. Prior to release 4.0B these adjustments had to be made manually using upgrade utilities. From release 4.5A, this procedure has been automated with the modification assistant.
- Enhancements: this means creating repository objects for individual customers that refer to objects that already exist in the SAP repository.
- Customer developments: this means creating repository objects unique to individual customers in a specific namespace reserved for new customer objects.
Customizing and Personalization
- Customizing and most personalization is done using tools found in AcceleratedSAP.
- Customer developments, enhancements, and modifications are all made using the tools available in the ABAP Workbench.
- The business engineer is made up of all SAP implementation tools. These include:
- The R/3 reference model
- Contains all of the models used to describe R/3 (the process model, the data model, the organization model)
- The implementation guide (IMG)
- A complete list of all customizing changes
- The R/3 reference model
- Personalization accelerates and simplifies how business cases are processed by the R/3 system. During personalization, individual application transactions are adjusted to meet the business needs of your company as a whole or even to the needs of specific user groups within your company. All unnecessary information and functions found in the transaction are switched off.
- Global display attributes allow you to define default values for specific screen fields. You can also suppress individual fields or table control columns in a particular transaction, or even a whole screen.
- Role-based menus, favorites, and shortcuts allow you to adjust menu sequences to reflect the needs of different user groups within your company.
- The enhancement concepts SAP programs call repository objects that you, as a customer, created or changed. Example: you use a function module exit called by an SAP program. You can enhance your system at the following levels:
- In ABAP programs (function module exit)
- On GUI interfaces (menu exit)
- On screens by inserting a subscreen in an area specified by SAP (screen exit)
- On screens by processing customer code that refers to a specific field on the screen (field exit)
- In ABAP dictionary tables or structures (table enhancement)
- SAP provides two ways to enhance tables and structures with fields.
- Customizing includes ("CI includes")
- Both techniques allow you to attach fields to a table without actually having to modify the table itself.
- Append structures may only be assigned to a single table. A table may, however, have several append structures attached to it. During activation, the system searches for all active append structures for that table and attaches them to the table.
- Field exits need not be prepared by the SAP application developer. You can create a field exit for any screen input field that has a dictionary reference. The reference object is the data element.
Creating a Field Exit
- To create a field exit, you need to first determine which data element you would want to change, the program that you would like to have the effect on, the screen number.
- Start transaction CMOD
- Choose text enhancements a field exits
- To create a new field exit use the menu path field exit à create
- In the pop up enter the data element name and click on continue.
- Next you will be taken to the ABAP/4 function library initial screen, where you will find a default function module name for the selected data element is displayed.
- Click on the create button to create the function module for the field exit.
For the field exits we do not need an enhancement project.
- You will be prompted for a function group. If you have already created a function group, you can specify its name else a function group can be created by entering a new function group name in the pop up screen. It will prompt you for creation of the function group. Click `yes' to create one. Next it will ask you to enter a short text for the function group and click on save button on the popup screen. Now you will be prompted to assign a development class. Assign a development class and click on save icon.
- Now you will be taken to function module administration screen. Field exit functional module initial screen…
- Here you enter the application and a short text for the field exit function module and save it.
- Enter a meaningful short text for the field exit…
- Now click on source code button on the application toolbar to write the functionality of the field exit.
- After you enter into the function module editor enter the code for field exit. Save the code and activate the function module.
- Now click on back icon twice.
- In the data element pop up screen that you get press cancel
- You will now come to the fields exits for data elements screen.
- Select the data element and click on assign Prog / screen. Selected the data element…
- In the pop up screen that you get enter the program name and the screen number and then click on the save icon.
- You will be displayed to edit the change request number. Click on edit.
- Now activate the field exit by selecting the data element and then the menu path field exit à activate.
- Click on the back icon to come to the initial screen.
Program Enhancement (Function Module Exit)
- The purpose of a program enhancement is always to call an object in the customer namespace. You can use the following techniques here:
- A special exit function module is called by the SAP application program. The function module is part of a function group that is handled in a special manner by the system.
- Business transaction events : The SAP application program dynamically calls a function module in the customer namespace.
- Business add-ins : The application program calls a method of a class or instance of a class. This class lies in the customer namespace.
Program Exit Overview
Calling and Creating Function Modules
- SAP application programmers use the ABAP statement CALL CUSTOMERFUNCTION 'nnn' to call function modules, where nnn is a three-digit number. (Where 'nnn' is a three-digit number). The application programmer must also create the function module he wants to call and its related function group.
- These function modules belong to function groups whose names begin with X (X function groups).
- The following naming convention applies to these function modules:
- Prefix: EXIT
- Name: name of the program that calls the function module
- Suffix: three-digit number
- The three parts of the name are separated by two underscores.
- The CALL CUSTOMER-FUNCTION statement is only executed if the enhancement project has been activated. Multiple calls of the same function module are all activated at the same time.
Finding Function Module Exits
Finding Function Module Exits
- To see quickly if an application program offers a function module exit, you can follow the path on the left-hand side of the graphic: (the menu path system à status always displays the name of the current application program). In our example a suitable character string would be "CALL CUSTOMER". Use the find icon and search globally in the program. If your search does not provide any results, you can define a larger search area. Determine the environment for the corresponding program and look for the specific character string in the program environment.
- The right side of the graphic shows you how to find the name of the required enhancement using search tools. You can restrict the search in the R/3 repository information system using different criteria: these are:
- Development class (also try generic entries)
- Technical name of the enhancement
Editing Function Module Exits
- Use the project management (transaction: CMOD) function to edit function modules for function module exits.
- Use the button for editing components to go directly to the function module editor (display mode).
- DO NOT change the function module itself. It is especially important that you do not alter the interface in any way. The function module, however, contains an INCLUDE statement for an include program that you have to create in the customer namespace.
- Double-click on the include name beginning with ZX. This automatically takes you to the editor of the include program, where you can enter your code.
- Menu enhancements permit you to add additional menu entries to an SAP standard menu. The system provides two options here:
- Customer exits
- Business add-ins
- The additional menu entries are merged into the GUI interface.
- When the function code is implemented, you can change the text of the menu entry, and - provided the SAP developer specified this option - change the icons.
Creating a Menu Exit
- Evoke the Transaction Code CMOD or alternatively you can use the Path Tools → ABAP/4 Workbench → Utilities → Enhancements → Project Management.
- Specify a Project Name in the Enhancement Text box.
- Click on the Create icon on the application toolbar. If the Project Already exists then click on the Change button. Give a Enhancement Project Name here.
- In the next screen enter a Description of the Project
- Save the Changes that you made so far in a Development Class.
- Click on SAP Enhancement button on the application toolbar. In the screen that you get press F4. You will get a pop up box. On this box click on “Enter” icon. You will get a list of Enhancements provided by SAP Give a meaningful description for the Enhancement Project.
- Click on the copy button on the application toolbar.
- You will get back to the enhancement list screen
- Click on the SAVE icon to save the changes
- Click on back icon twice to get back to the initial screen
- Now select enhancement components radio button click on change.
- In the following screen you will get the list of enhancement components that you had selected for modifications.
- Select the component that you want to edit and click on edit component Button on the application toolbar selected enhancement component for menu exit…
- You will get a popup screen in which you can enter a new text for Our menu option. Let's enter `test menu exit'.
- Click on the save icon and then click on the BACK button on the same box.
- Click on back icon to get back to the initial screen
- Click on activate project to activate the changes.
- To check whether the component has been activated or not, choose tools -> ABAP/4 workbench development.
- Here change the language and give a description to your menu item. Give a meaningful description
- You should see your menu entry now.
- To make this menu option functional, you need to create a transaction with a transaction code associate this transaction code with the report / Dynpro that you would like to execute at this menu option selection.
Menu Exit – Summary
- You can implement menu exits based on reserved function codes. The SAP application programmer defines the relevant function codes, assigns them to menus, and often provides a function module exit.
- Menu exits and function module exits are both part of the same SAP enhancement.
- No pushbuttons may be assigned to additional function codes.
- You can, however, make changes to the various menu entries and activate their function codes.
- Screen exits belong to the customer exits. They allow you to display additional objects in an SAP application program screen. The SAP developer must:
- Define the subscreen areas
- Specify the corresponding calls in the flow logic
- Provide the framework for the data transport
- Include the screen exit in an enhancement
- Maintain the documentation
- You can implement screen exits by creating subscreens, possibly with flow logic. You also have to implement the data transport.
Creating a Screen Exit
- Create an enhancement project
- Save the enhancement project
- Click on the SAP enhancement radio button on the initial screen. Note: if you are adding this screen exit component to an existing enhancement project, then deactivate it first by clicking on the deactivate button the application toolbar.
- After selecting the SAP enhancement radio button click on change Button on the initial screen
- You will get into SAP enhancement screen place the cursor in one of the box and press F4 to get the list of SAP enhancement components either click on enter icon or specify a dev. Class….
- After you will click on the enter key you will get a list of exits available for this development class.
Defining Screen Exit
Creating a Screen Exit Contd…
- Select the screen exit that you would like to add
- Click on the copy button.
- You will now the see the screen enhancement component in the list of components of the enhancement project.
- Click on the save icon and the click on the back icon to get back to the initial screen. List of SAP enhancement components in a enhancement project ….
- Now on the initial screen select the enhancement components radio button and click on change.
- You will get a list of enhancement components along with their exits.
- Select the exit and double click on it. Specify the screen as Subscreen in the screen attributes area. Select your enhancement component and double click on it to add your functionality to the component…
Creating a Screen Exit Contd…
- In the screen painter screen make the changes by adding your own objects.
- For the field objects, check the SET and GET parameter check boxes in their attribute screen.
- Now save and generate the screen.
- Click on the back icon to get back to the initial screen.
- Click on activate project button to activate the project.
- Next execute the program
Any change that you make your system to an object that has been delivered by SAP is known as a modification.
Modifications can lead to complications at upgrade. When SAP delivers a new version of the object, you must decide whether the new object should be used, or whether you want to continue using your old object.
Prior to release 4.0B, modifications were only recorded at repository object level (for example, an include program).
Since release 4.5A, the granularity for recording modifications has been finer. This has been made possible by the modification assistant.
Corrections / Repairs in R/3 System
- Changes to an original are called corrections. They are recorded in a change request whose tasks have the type "development/correction".
- If, on the other hand, you change a copy (an object outside its own original system), the change is recorded in a task with the type "repair". Repairs to SAP objects are called modifications.
- When you repair your own objects (for example, if something goes wrong in your production system), you can correct the original in your development system straight away. When you change copies, you must correct the original immediately!
- However, you cannot do this with SAP objects, because they are not original in any of your systems.
- You should only modify the SAP standard if the modifications you want to make are absolutely necessary for optimizing workflow in your company. Be aware that good background knowledge of application structure and flow are important prerequisites for deciding what kind of modifications to make and how these modifications should be designed.
Structure of Module Pool
Structure of Module Pool
- A module pool is organized as a collection of include programs. This is particularly useful for making the program easier to understand. The organization is similar to that of function groups. In particular, the naming convention, by which the last three letters of the name of the include program identify its contents, is identical.
- The main program, as a rule, contains the include statements for all of the include programs that belong to the module pool.
- The includes described as "special" includes in the program are themselves only include programs - technically, they are not different. These programs are only delivered once.
- User exits are a type of system enhancement that were originally developed for the R/3 sales and distribution module (SD). The original purpose of user exits was to allow the user to avoid modification adjustment.
- A user exit is considered a modification, since technically objects in the SAP namespace are being modified.
- The SAP developer creates a special include in a module pool. These includes contain one or more subroutines routines that satisfy the naming convention userexit_. The calls for these subroutines have already been implemented in the R/3 program. Usually global variables are used.
- After delivering them, SAP never alters includes created in this manner; If new user exits must be delivered in a new release, they are placed in a new include program.
Why Do We Need to Use Exits?
There are mainly two reasons to why we have to use exits if we ever Have to.
1. You should them because they do not effect the SAP source code but still allow you to change the functionality of SAP to suit your needs. SAP has provided us with some standard exits that we should modify by adding our own functionality to them. The code and screens you create are encapsulated as separate objects. When you create exits, they are encapsulated as separate objects.
2. And since, they do not effect the source code and are named as per the SAP naming conventions, they do effect future software upgrades. Hence you do not have to save them and then renter add-ons attached to exits.
You can only use exits if they already exist within the SAP R/3 system In case you do not find an exit available for an area where you would Want to make a change, then you should request SAP to develop an exit.
User Exit: Example
Example: Program: SAPM45A, Include: M45AFZB This naming convention guarantees that SAP developers will not touch this include in the future. For this reason, includes of this nature are not adjusted during modification upgrade.
- User exits are actually empty subroutines that SAP developers provide for you. You can fill them with your own source code.
- The purpose behind this type of system is to keep all changes well away from program source code and store them in include programs instead. To this end, SAP developers create various includes that fulfil the naming conventions for programs and function groups. The last two letters in the name of the include refer to the include that the customer should use: "Z" is usually found here.
- The subroutine call is already implemented in the program. The interface is already defined. Normally, subroutines of this type only work with global data.
- If any new user exits are delivered by SAP with a new release, then they are bundled into new includes that adhere to the same naming convention.
Using User Exit’s
- You can find a list of all user exits in the SAP reference implementation guide.
- There, you will also find documentation explaining why SAP developers have created a particular user exit.
- Follow the steps described in the implementation guide.
- The aim of the modification assistant is to make modification adjustments easier. In the past, the granularity of modifications was only at include program level. Today, a finer granularity is available. Now, modifications can be recorded at subroutine or module level.
- This is because (among other reasons) the modifications are registered in a different layer. As well as providing finer granularity, this means that you can reset modificaitons, since the original version is not changed.
Modification Adjustments Then and Now
Modification Assistant: Tools Supported
Modification Assistant Icons
- In modification mode, you have access to a subset of the normal editor tools. You can access these using the appropriate pushbuttons. For example, in the ABAP editor, you can:
- Insert -the system generates a framework of comment lines between which you can enter your source code.
- Replace -position the cursor on a line and choose replace. The corresponding line is commented out, and another line appears in which you can enter coding. If you want to replace several lines, mark them as a block first.
- Delete -select a line or a block and choose delete. The lines are commented out.
- Undo modifications -this undoes all of the modifications you have made to this object.
- Display modification overview -choose this function to display an overview of all modifications belonging to this object.
Modification Assistant: Example ABAP Editor
Modification Assistant: Restoring the Original
You can reset all of the modifications that you have made to the current object using the modification assistant by choosing this function. The record of the modifications is also deleted.
Remember that you cannot selectively undo modifications to an object. You can only undo modifications based on the "all or nothing" principle.
- SE84 –repository information system
- SMOD –enhancement
- CMOD –project definition
- SE80 –object navigator
- SPRO –customization
Download attached file:
You must be Loged in to download file