Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

user-exit vf02

Former Member
0 Likes
1,628

hello experts!!

can you help me on how to find the user-exit of vf02.i need to find the user-exit of the condition tab in vf02.

points will be given..

thanks.

hello experts!!

can you help me on how to find the user-exit of vf02.i need to find the user-exit of the condition tab in vf02.

points will be given..

thanks.

6 REPLIES 6
Read only

Former Member
0 Likes
1,219

Hi,

Pls. check the user exits of given tcode.

Exit Name Description

SDVFX007 User exit: Billing plan during transfer to Accounting

SDVFX008 User exit: Processing of transfer structures SD-FI

SDVFX009 Billing doc. processing KIDONO (payment reference number)

SDVFX010 User exit item table for the customer lines

SDVFX011 Userexit for the komkcv- and kompcv-structures

V05I0001 User exits for billing index

V05N0001 User Exits for Printing Billing Docs. using POR Procedure

V60A0001 Customer functions in the billing document

V60P0001 Data provision for additional fields for display in lists

V61A0001 Customer enhancement: Pricing

SDVFX001 User exit header line in delivery to accounting

SDVFX002 User exit for A/R line (transfer to accounting)

SDVFX003 User exit: Cash clearing (transfer to accounting)

SDVFX004 User exit: G/L line (transfer to accounting)

SDVFX005 User exit: Reserves (transfer to accounting)

SDVFX006 User exit: Tax line (transfer to

accounting)

To know hoe to get these...Pls run the below code.

report zuserexit no standard page heading .

tables :

tstc,

tadir,

modsapt,

modact,

trdir,

tfdir,

enlfdir,

tstct.

*----


*INTERNAL TABLES AND STRUCTURES

*----


*Internal table to hold Repository Objects

data : jtab like tadir occurs 0 with header line.

*----


*Global variables

*----


data : field1(30).

data : v_devclass like tadir-devclass.

*----


*SELECTION-SCREEN

*----


parameters : p_tcode like tstc-tcode obligatory.

*----


*START-OF-SELECTION

*----


START-OF-SELECTION.

*SELECT construct to get data for a given tcode

select single * from tstc where tcode eq p_tcode.

if sy-subrc eq 0.

*SELECT construct to get program names

select single * from tadir where pgmid = 'R3TR'

and object = 'PROG'

and obj_name = tstc-pgmna.

*Moving the dev. class to v_devclass if program is of type 1

move : tadir-devclass to v_devclass.

if sy-subrc ne 0.

select single * from trdir where name = tstc-pgmna.

*If Program type = Function Group

if trdir-subc eq 'F'.

select single * from tfdir where pname = tstc-pgmna.

*SELECT construct to get Attributes for Function Modules

select single * from enlfdir where funcname = tfdir-funcname.

*SELECT construct to get FM names

select single * from tadir where pgmid = 'R3TR'

and object = 'FUGR'

and obj_name eq enlfdir-area.

*Moving the dev. class to v_devclass if program is of type F

move : tadir-devclass to v_devclass.

endif.

endif.

*SELECT construct to get SAP enhancements for the dev. class

select * from tadir into table jtab

where pgmid = 'R3TR'

and object = 'SMOD'

and devclass = v_devclass.

*SELECT construct to get t code texts

select single * from tstct

where sprsl eq sy-langu

and tcode eq p_tcode.

*REPORT OUTPUT

format color col_positive intensified off.

*Displaying t-code name & text

write:/(19) 'Transaction Code - ',

20(20) p_tcode,

45(50) tstct-ttext.

skip.

*List headings

if not jtab[] is initial.

write:/(95) sy-uline.

format color col_heading intensified on.

write:/1 sy-vline,

2 'Exit Name',

21 sy-vline ,

22 'Description',

95 sy-vline.

write:/(95) sy-uline.

*SELECT construct to get SAP Enhancements - Short Texts

loop at jtab.

select single * from modsapt where sprsl = sy-langu

and name = jtab-obj_name.

format color col_normal intensified off.

*Exit names & texts

write:/1 sy-vline,

2 jtab-obj_name hotspot on,

21 sy-vline ,

22 modsapt-modtext,

95 sy-vline.endloop.

write:/(95) sy-uline.

describe table jtab.

skip.

format color col_total intensified on.

*No of Exits

write:/ 'No of Exits:' ,

sy-tfill.

else.

format color col_negative intensified on.

*If no exits found

write:/(95) 'No User Exit exists'.

endif.

else.

format color col_negative intensified on.

*If tcode doesn't exist

write:/(95) 'Transaction Code Does Not Exist'.

endif.

*Call txn SMOD with selected Exit

at line-selection.

get cursor field field1.

check field1(4) eq 'JTAB'.

set parameter id 'MON' field sy-lisel+1(10).

call transaction 'SMOD' and skip first screen.

Pls. reward if useful...

Read only

Former Member
0 Likes
1,219

use transaction CMOD and find for Billing component under SD .

You will get a list of all the User-Exits that are available .

Read only

Former Member
0 Likes
1,219

HI,

I suppose there are few exits available for triggering logics for VF02.

You can use the following includes for your reqts:

RV60AFZA

RV60AFZB

RV60AFZC

RV60AFZD

RV60AFZJ

RV60AFZZ.

In these exits, under RV60AFZZ there are subroutines:

FORM USEREXIT_ACCOUNT_PREP_KOMKCV,

FORM USEREXIT_ACCOUNT_PREP_KOMPCV,

FORM USEREXIT_PRICING_PREPARE_TKOMK,

FORM USEREXIT_PRICING_PREPARE_TKOMP

where in any logics written inside this forms should trigger the condition tab in VF02. You'll require access key, if these pgms are to be edited for the 1st time.

Hope this helps.

Regards,

JLN

Read only

0 Likes
1,219

hi how did you find this? so next time ill know what i need to do.

Read only

0 Likes
1,219

Hi

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

.********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 in 1 project. If the enhancement is already 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"

Read only

Former Member
0 Likes
1,219

Hi,

  • Finding the user-exits of a SAP transaction code

*

  • Enter the transaction code in which you are looking for the user-exit

  • and it will list you the list of user-exits in the transaction code.

  • Also a drill down is possible which will help you to branch to SMOD.

*

*

report zuserexit no standard page heading.

tables : tstc, tadir, modsapt, modact, trdir, tfdir, enlfdir.

tables : tstct.

data : jtab like tadir occurs 0 with header line.

data : field1(30).

data : v_devclass like tadir-devclass.

parameters : p_tcode like tstc-tcode obligatory.

select single * from tstc where tcode eq p_tcode.

if sy-subrc eq 0.

select single * from tadir where pgmid = 'R3TR'

and object = 'PROG'

and obj_name = tstc-pgmna.

move : tadir-devclass to v_devclass.

if sy-subrc ne 0.

select single * from trdir where name = tstc-pgmna.

if trdir-subc eq 'F'.

select single * from tfdir where pname = tstc-pgmna.

select single * from enlfdir where funcname =

tfdir-funcname.

select single * from tadir where pgmid = 'R3TR'

and object = 'FUGR'

and obj_name eq enlfdir-area.

move : tadir-devclass to v_devclass.

endif.

endif.

select * from tadir into table jtab

where pgmid = 'R3TR'

and object = 'SMOD'

and devclass = v_devclass.

select single * from tstct where sprsl eq sy-langu and

tcode eq p_tcode.

format color col_positive intensified off.

write:/(19) 'Transaction Code - ',

20(20) p_tcode,

45(50) tstct-ttext.

skip.

if not jtab[] is initial.

write:/(95) sy-uline.

format color col_heading intensified on.

write:/1 sy-vline,

2 'Exit Name',

21 sy-vline ,

22 'Description',

95 sy-vline.

write:/(95) sy-uline.

loop at jtab.

select single * from modsapt

where sprsl = sy-langu and

name = jtab-obj_name.

format color col_normal intensified off.

write:/1 sy-vline,

2 jtab-obj_name hotspot on,

21 sy-vline ,

22 modsapt-modtext,

95 sy-vline.

endloop.

write:/(95) sy-uline.

describe table jtab.

skip.

format color col_total intensified on.

write:/ 'No of Exits:' , sy-tfill.

else.

format color col_negative intensified on.

write:/(95) 'No User Exit exists'.

endif.

else.

format color col_negative intensified on.

write:/(95) 'Transaction Code Does Not Exist'.

endif.

at line-selection.

get cursor field field1.

check field1(4) eq 'JTAB'.

set parameter id 'MON' field sy-lisel+1(10).

call transaction 'SMOD' and skip first screen.

*---End of Program

BY USING THIS PROGRAM U CAN GET THE USEREXIT BY INPUTTING THE TRANSACTION CODE.

REGARDS,

PRIYA.