Function Module Exit - SAPCODES PDF
Function Module Exit - SAPCODES PDF
Function Module Exit - SAPCODES PDF
SAPCODES
ABAP OO-ABAP ENHANCEMENTS RFC & BAPI ALE-IDOC USEFUL PROGRAMS WEBDYNPRO
Scenario: Defaulting the SOLD-TO-PARTY value while creating the sales order
in VA01 transaction by using FUNCTION MODULE EXIT.
RECENT POSTS
Step1. Go to Tx- SE93 and provide Tcode- VA01 & hit display button and get the UI5 App Table with
Follow
BLOG STATS
1,141,877 hits
RECENT COMMENTS
https://sapcodes.com/2015/11/20/function-module-exit/ 1/11
6/6/2019 Function Module Exit – SAPCODES
Step6. From the list of Enhancements available in the Package, for our case lets
choose the underlined one( double click on the decided enhancement).
https://sapcodes.com/2015/11/20/function-module-exit/ 2/11
6/6/2019 Function Module Exit – SAPCODES
Step10. These function module interface parameters are available to determine the
sold-to-party and can be assigned to the Exporting parameter e_kunnr.
https://sapcodes.com/2015/11/20/function-module-exit/ 3/11
6/6/2019 Function Module Exit – SAPCODES
Step14. Open KNVV table entreis. Here we can see customer- 0000099994 .
https://sapcodes.com/2015/11/20/function-module-exit/ 4/11
6/6/2019 Function Module Exit – SAPCODES
Step15. Let’s create a project to default the SOLD-TO-PARTY value. Go to Tx- CMOD
& provide a Project name and click on Create button.
Step16. Provide the short text and click on the Enhancement assignment button.
Step17. Provide the enhancement name decided from SMOD transaction and hit
enter button. At last click on Components button.
https://sapcodes.com/2015/11/20/function-module-exit/ 5/11
6/6/2019 Function Module Exit – SAPCODES
Step20. Hit the Enter key from the keyboard. From the appeared pop up click on Yes
button.
Step21. Provide the below code. Here just we have hard coded the sold-to–party
vale. But the value of the sold-to-party can be decided dynamically from the
importing parameters of the function module.
https://sapcodes.com/2015/11/20/function-module-exit/ 6/11
6/6/2019 Function Module Exit – SAPCODES
Step25. Now again run – Tx- VA01 and provide the values & hit enter.
Step26. The debug point reached and we can see the function modules importing
parameters. Double click on the parameter : I_TVTA.
https://sapcodes.com/2015/11/20/function-module-exit/ 7/11
6/6/2019 Function Module Exit – SAPCODES
Step27. The structure I_TVTA contains the below values which can be used to
dynamically decide any sold-to-party depending on the business requirement. Click
on F8.
Step29. Let’s nd where this function module exit is called in the standard VA01
transaction. From Tx- SE93 get the program name for the Tx- VA01.
https://sapcodes.com/2015/11/20/function-module-exit/ 8/11
6/6/2019 Function Module Exit – SAPCODES
Step30. Open the Program in Tx- SE38 and click on the nd button.
Step31. Search for the Key Word ‘call customer-function’ and select main program
radio button.
Step32. Here we can see ‘ call customer-function ‘002’ -> our function module also
ends with 002 , which calls the function module ‘EXIT_SAPMV45A_002’ .
https://sapcodes.com/2015/11/20/function-module-exit/ 9/11
6/6/2019 Function Module Exit – SAPCODES
Advertisements
REPORT THIS AD
REPORT THIS AD
Rate this:
Rate
Related
https://sapcodes.com/2015/11/20/function-module-exit/ 10/11