Function Module Exit Part 2
- We have discussed what are Customer Exit and their different types as well.
- Also, In the Previous parts we have seen how we can find the function Module Exit for our requirement through debugging.
- In this part, we will see how to find function module using another technique.
Suppose, we want to find function module exit for our VA01 transaction code.
Steps to find Customer Exit ( Function module Exit ) :-
-
Step 1 :- Go to VA01 transaction code.
-
Step 2 :- Click on system → status.
-
Step 3 :- Copy the name of the program.
-
Step 4 :- Now go to SE38 ( ABAP Editor ) transaction code and select the Attributes radio button.
-
Step 5 :- Click on display, it will return you the package name.
-
Step 6 :- Copy the package name and Go to SMOD transaction code.
-
Step 7 :- Click on utilities → find.
- Click on execute button.
-
We can see we have a lot of Customer Exit available here, which also contains the Customer Exit for out requirement which is Sold to Party.
-
Step 8 :- Double click on Sold to Party Customer exit.
- It will show all the function module exit , menu exit and customer exit if they are available.
Steps For Implementing Customer Exit :-
-
Step 1 :- Go to CMOD transaction code.
-
Step 2 :- Provide the project name and click on create button.
-
Step 3 :- Click on enhancement assignment and provide the name of the customer exit that we have found for our Sold to Party.
-
Step 4 :- Click on the Components tab, it will show us the components of the above given customer exit.
-
Step 5 :- Click on activate button to activate the implementation of our customer exit.
Writing the logic for Sold to Party Function Module Exit.
-
Step 1 :- Copy the name of the above function module exit and go to SE37 transaction code.
- We can see we have a exporting parameter, E_KUNNR which we can use for transporting purpose.
-
Step 2 :- Go to source code and open the given include in change mode and write the below logic.
Testing the Implementation :-
-
Step 1 :- go to VA01 transaction code and give the below order type.
- Press enter.
- We can see the Sold to Party is getting auto populated.
Note :-
- Always remove the code from function module exit after practicing it.
Comments
Post a Comment