cancel
Showing results for 
Search instead for 
Did you mean: 

Exit

Former Member
0 Kudos

Can anyone give a realtime example about exits (Field exit or user exit) in detail?

Thank you in advance

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

Few examples of real time use of exits:

1). If there is a need to send some notification to some one if there is a neew idoc coming in for orders or for other business documents

2). If you want to throw some errors based on some custom checks.

3). If you want to restrict some users to perform from some typical operations within a business transactions.

The list is endless. Most of All that you would want to do in your business process which is not available in std SAP and also not available in Customizing is either implemented using a userexit or by creating a custom development all together.

Cheers

VJ

Message was edited by: Vijayendra Rao

Former Member
0 Kudos

Hello Austtin,

FE can be used for validation of a perticular field. Say for e.g in purchase order creation, u want to validate purchase group based on the entry done in company code and purchase org. u can achieve this. Similarly user exits are SAP provided which can be used to do validations, can add screens to the std SAP and many more.

Former Member
0 Kudos

Hai go through this document that will help you

User Exits

Screen exits are exits that allow you to use a reserved part of the screen (A subscreen) to display or input data.

It is determined be SAP where the sub screen will be displayed.

The syntax is: CALL CUSTOMER-SUBSCREEN

The screen exit is not processed untill the corresponding subscreen has been created in an enhancement project,

and the project has been activated.

Note:

Function codes are only processed in the main screens flow logic

You are not allowed to enter a name for the subscreens command field

You are not allowed to define GUI stauses

You are not allowed to enter a value for Next screen

The global data of the program is not available for the subscreen. Data for the subscreen is provided by function modules.

These function modules belongs to the same function group as the subscreen Subscreens are edited with transaction CMOD.

When you activate a project containg subscreens, the calling screen is regenerated and the subscreen is displayed next

time you display the calling screen

The developer must create the subscreen and the corresponding PBO and PAI modules

How to identify screen exits

Look after CALL CUSTOMER-SUBSCREEN in the screenprogram of the screen you want to modify.

Use transaction CMOD menu Utillities -> SAP enhancements to search for screen exits

MENU EXITS

Menu exits allow you to add your own functionallity to menus. Menu exits are implemented by SAP, and are reserved menu

entries in the GUI interface. The developer can add his/her own text and logic for the menu.

Function codes for menu exits all start with "+"

Example

We want to create a new menu item in the Office menu. The text for the menu should be "Run ZTEST", and the menu will

run report ZTEST.

Goto transaction SE43 Area Menu Maintenance

In Area Menu Paramenter type 'S000' (S triple Zero)

Select Change and ignore all the warning screens

Expand the office menu. In the buttom of the office tree you will find a menu named "Customer function"

Double click on the text. In the pop-up screen change the text to "Run ZTEST". Note that the trsnaction code is +C01

Goto transaction SE93 and create transaction +C01 that calls report ZTEST.

Now you will se the menu displayed in the office tree. If you delete transaction +C01 again, the new menu will dissapear.

USER EXITS

User exits (Function module exits) are exits developed by SAP. The exit is implementerd as a call to a functionmodule.

The code for the function module is writeen by the developer. You are not writing the code directly in the function module,

but in the include that is implemented in the function module.

The naming standard of function modules for functionmodule exits is: EXIT_<program name><3 digit suffix>

The call to a functionmodule exit is implemented as: CALL CUSTOMER.-FUNCTION ❤️ digit suffix>

Example:

The program for transaction VA01 Create salesorder is SAPMV45A

If you search for CALL CUSTOMER-FUNCTION i program SAPMV45A you will find ( Among other user exits):

CALL CUSTOMER-FUNCTION '003'

exporting

xvbak = vbak

xvbuk = vbuk

xkomk = tkomk

importing

lvf_subrc = lvf_subrc

tables

xvbfa = xvbfa

xvbap = xvbap

xvbup = xvbup.

The exit calls function module EXIT_SAPMV45A_003

2. How to find user exits

Display the program where you are searching for and exit and search for CALL CUSTOMER-EXIT

If you know the Exit name, go to transaction CMOD. Choose menu Utillities->SAP Enhancements.

Enter the exit name and press enter.

You will now come to a screen that shows the function module exits for the exit.

3. Using Project management of SAP Enhancements

We want to create a project to enahance trasnaction VA01

Go to transaction CMOD

Create a project called ZVA01

Choose the Enhancement assign radio button and press the Change button

In the first column enter V45A0002 Predefine sold-to party in sales document . Note that an enhancement can only

be used i 1 project. If the enhancement is allready in use, and error message will be displayed

Press Save

Press Components. You can now see that enhancement uses user exit EXIT_SAPMV45A_002. Double click on the exit.

Now the function module is displayed. Double click on include ZXVVAU04 in the function module

Insert the following code into the include: E_KUNNR = '2155'.

Activate the include program. Go back to CMOD and activate the project.

Goto transaction VA01 and craete a salesorder. Note that Sold-to-party now automatically is "2155"

Have look at this links

Thanks & regards

Sreenivasulu P