Using Perfrom in User exit
HI Gurus,
can u use perform in user exit , say for example i am enhasing a data source 2LIS_11_VAITM , can i use the PERFORM xxxxxxx.
FORM XXXXX.
SOME CODE .
ENDFORM.
When i am trying to do this is am getting error sating
" Incorrect nesting: Before the statement "FORM", the structure ,introduced by "LOOP" must be concluded by "ENDLOOP". - "
can any one suggest what is the probelm..
Hi,
Please check if you're used a LOOP somewhere and not closed it properly.
In any case its better to go with a Function module in a user exit.
Cheers,
Kedar
Similar Messages
-
Change MOT in purchase order using CIF Inbound user exit
Hello APO Experts,
Objective is to change start date of purchase order ( date at source location) in APO based on some date in R3.
Planning to bring R3 date using CIF Outboud user exit( CIFPUR01) in R3 and then further requirement is to a) calculate lead time in inbound user exit ( APOCF006) of purchase order in APO b) compare it with lead time of all available Means of Transport in that particular TLane and select one MOT say XX which matches that lead time c) Next part is to change existing MOT in the Purchase order and replace it with the new XX MOT.
For part c....I am wondering how can we change existing MOT in purchase order and replace it with a new one.Can it be achieved by the user exit APOCF006 in APO or something else is required.
Will appreciate your quick reply on this issue.
Thanks
Best RegardsHi Nilesh
We have a similar requirement. I know its way long for you to remember but i would appreciate if you could share what did you do to achieve this.
Thanks
Abhishek Rai -
How to use subroutine in user-exit program
Hi Experts,
I have a requirement in user-exit where i have to use some lines of code in several times. So i want to use Perform and perform inside the exit (i.e. Include ZXXX). But it is not recognizing the form part of the ubroutime and gives error.
Please let me know how to use the Perform and form statement in the exit or is there any way to write repeated code once but used no of times in exit program.
Thanks
AjitI'm sorry, I was overly harsh there. Please accept my apologies. But I do despair sometime!
Consider the structure of a function group and it should be clear - you need to remember that INCLUDES are just repositories of code. If you take the contents out of the include and put them into the main program, then this is what you get:
function-pool xrsr.
* Global data definition.
function exit_saplrrs0_001.
* the source code within the zxrsru01 include.
endfunction.
Now, what you're trying to do, is create a form in your include. You can't do that, because you end up with:
function-pool xrsr.
* Global data definition.
function exit_saplrrs0_001.
perform xyz.
form xyz.
endform.
endfunction.
And you can't have a FORM defined inside a function module definition. The solution is to put it outside the function module. If you follow the process suggested above, you end up with
function-pool xrsr.
* Global data definition.
function exit_saplrrs0_001.
perform xyz.
endfunction.
form xyz. " This will be in LXRSRF01
endform.
Do you see how it works now? -
User Exit to be used in Substitution
Hello,
We have recently got an requirement from one of the clients as they want to copy the material description to the GL text field (against Doc Type WA & WE) . I am able to find that this can be achieved by way of creating substitution, but I wander which user exit to be used for this purpose.
Its been my experience that when ever a question of user exit arise I go blank as which user exit to be used, where will I get all this information with clear update motioning the purpose or use of each SAP delivered user exit.
I have tried goggling it out but I was not able to find much use full stuff. Please share your expertise.
Thanks a ton in advance,
Regards,
ShilpaHi Shilpa,
there is no hard code rule to use the specific user exit for substitutions, attached screen shots will help you to resolve the issue.
Step 1: Go to the t.code: OKC9, specify the controlling area and event 0001.
Step 2 : Create the substitution and select the step (attachment 1)
Step 3: below mentioned screen shot specify the any existing user exit (naming conversion starts with U) by F4 option and double click on the particular exit
Step 4: you can see the Report ZGGBS800, here you can create the user exit next free number starts with U naming conversion, once it's created the replace the existing user exit in the substitution rule.
Hope this will help you to understand the user exit process in substitution rule.
Note: Only substitution rules there is no hand code rule for user exit, for other transactions we need to check the SAP delivered exits.
Make sure that substitution rule must be activated once exit created
Thanks & Regards
Srinu -
Changing sales office in sales office using save_document user exit
Hi,
My requirement is to change the sales office to 109 based on some conditions.
Here i am using FORM USEREXIT_SAVE_DOCUMENT user exit in the sales order to do it.
but it is not taking this value .
Can any one suggest me any other place i.e. user exit where we can change sales office depending on some conditions.
Thanks & regards
Manjari.You have to use userexit 'USEREXIT_SAVE_DOCUMENT_PREPARE' because when exit 'USEREXIT_SAVE_DOCUMENT' is called all the order data has already been submitted into update task. So if you want to change data in the order and have it saved with it you need to use 'USEREXIT_SAVE_DOCUMENT_PREPARE'.
Regards,
Michael -
Use of BAPIs in user exit macros
Is it ppssible to use BAPIs in user exit macros in the APO MacroBuilder?
Thanks for any advice on this...Hi,
Not sure what function you want to acheive, but basicly you can use any code in the user-exit macro's customizing code, but at last you must fill in the spcified return value to make the user-exit macro work.
Best Regards,
Ada -
Hi,
Can some one provide me how to use a standard User Exit.
I have entered the exit number in the enchamcements and when i go to components and double click the include in the function exit, i am getting the message Program names zx...are reserved for includes for exit function groups.
How can i change this to display mode and write my code.
Regards,
SudhirHi,
See Following information about user exits:
If Z include is not allowing U should click the 'Enter' button and then click the 'Yes' button. Now u are allowed to put u r own code.
Userexit is a methodology using which we can add our custom code in the SAP Standard transaction without disturbing the SAP Standard code. SAP will provide enhancement for one transaction. We can have more then one enhancement. Enhancement is a container with a set of userexits. SAP will provide only definition of the exit. Which does not contain any standard code. In the relevant transaction program SAP will their exit as a standard. The Userexit needs to be implemented inorder to provide a custom logic to serve business requirement.
SMOD: It is used to find the enhancement related to different applications.
CMOD: It is used to implement the userexit.
There are 4 types of exits available:
1) Function-module Exits,
2) Menu exits,
3) Screen exits and
4) Field exits.
1) Functionmodule exits:
These exits are used to provide additional functionality to SAP standard transaction. By default SAP is not provided this functionality.
For Example my requirement is, when user create or change customer and the customer belongs to US Country the Industry sector (brsch) field is not empty.
Step1: Find the enhancement. For that one goes to SMOD.
Click on F4 on Enhancement. We Search for enhancement. In this case we can found the enhancement by giving the Description: mast. We got the enhancement as
SAPMF02D: User exits: Customer master data.
(Or)
We find the enhancement at transaction level,
Go to XD01 transaction click on System/Status/double click on Program name
In this program we search for u201CCALL customer-functionu2019. We get the all related exits the starts with EXIT_enhancementname_Threedigitnumber. Sometimes it Will not an enhancement name.
Step2: Go to CMOD create the custom project.
Click on Enhancement assignments button
Give the Enhancement name: SAPMF02D
Step 3: Click on Components button. Under that we found the one function module:
EXIT_ SAPMF02D_001. Double Click on that function module. In the Source code tab of this function module SAP provide the one Zinclude. SAP doesnu2019t know our requirement. In this Zinclude we provide our own custom logic to make of the parameters provided in import, export and tables section.
We write the following code:
IF i_kna1-land1 = 'US' AND
i_kna1-brsch = ' u2018.
MESSAGE e001 (f2) WITH u2018 Industry sector should not be blank for US Customersu2019.
ENDIF.
Step4: SAVE, CHECH and ACTIVATE the Cutsom project.
Step5: Now go to XD01 Transaction We perform our requirement. After we donu2019t want that requirement go to CMOD and deactivated the custom project.
If it is helpful rewards points
Regards
Pratap.M -
As01 transaction using substitution user exit populate classificaion
Hi all,
I have a requirement, where in using the substitution user exit rule U210, I need to populate fields ANLB-NDPER, ANLB-NDJAR and ALNA-VMGLI from the values maintained in Ztable.
I am able to overwrite the SAP standard values for the fields ANLB-NDPER and ANLB-NDJAR. But not able to populate the filed VMGLI(Classification key).
For some asset classes, the classification key is not mandatory and the user without giving the value in that field if save the transaction, then I need to populate the value of VMGLI with the ztable value.
The present rule U210 is not working for classification key.
Please suggest, is there any other user exit for the scenario where we can populate VBGLI field.
regards
Rajani YeluriIn the user exit documentation, it doesn't say anything about this exit being used for validation, therefore, it probably shouldn't be used as a validation routine, especially if its not being trigger at every PAI.
<i>FU EXIT_SAPLAISA_001
Short text
Assign Inventory Number
Functionality
Using this user exit, it is possible to assign an inventory number when you create a new asset master record.
Notes
In the user exit, it is absolutely forbidden to use a statement that leads to an update or removal of database changes. Examples of such statements are:
'Commit Work' , 'Rollback Work' or call of function module 'DB_COMMIT'.
Parameter
I_ANLA
E_INVNR
Exceptions
Function group
XAIS</i>
Regards,
Rich Heilman -
As01 transaction using substitution user exit populate classificaion key
Hi all,
I have a requirement, where in using the substitution user exit rule U210, I need to populate fields ANLB-NDPER, ANLB-NDJAR and ALNA-VMGLI from the values maintained in Ztable.
I am able to overwrite the SAP standard values for the fields ANLB-NDPER and ANLB-NDJAR. But not able to populate the filed VMGLI(Classification key).
For some asset classes, the classification key is not mandatory and the user without giving the value in that field if save the transaction, then I need to populate the value of VMGLI with the ztable value.
The present rule U210 is not working for classification key.
Please suggest, is there any other user exit for the scenario where we can populate VBGLI field.
regards
Rajani YeluriHi,
Did you find a solution. I'm just looking for the same thing.
best regards.. -
As01 using substitution user exit populate classificaion key(ANLA-VMGLI)
Hi all,
I have a requirement, where in using the substitution user exit rule U210, I need to populate fields ANLB-NDPER, ANLB-NDJAR and ALNA-VMGLI from the values maintained in Ztable.
I am able to overwrite the SAP standard values for the fields ANLB-NDPER and ANLB-NDJAR. But not able to populate the filed VMGLI(Classification key).
For some asset classes, the classification key is not mandatory and the user without giving the value in that field if save the transaction, then I need to populate the value of VMGLI with the ztable value.
The present rule U210 is not working for classification key.
Please suggest, is there any other user exit for the scenario where we can populate VBGLI field.
regards
Rajani YeluriHi Balaji,
We have the same problem.
Have you discovered how to make this exit works?
We will really apreciate your help.
Thanks a lot,
Ivan Spellmeier -
F110 - Automatic Payment (User Exit, BTE, BADI)
I have requirement after generating payment document by F110 automatic payment. I need to send data to other system.
How to get all payment documents? Can I use a BTE, User Exit or BADI? Kindly help me.Hi ,
You can create a DMEE or genrate Idoc to another system .
If you want to send excel file then you can create a dmee file in transaction DMEE with same formt provided by bank/ another system .
many Thanks -
Hi,
I don't capture user-exits when press Goods Movements (sy-ucomm = MB03) and Save buttons in transaction CO11N.
I use the following user-exit:
FUNCTION EXIT_SAPLCORF_102 >>> Include ZXCOFU12
Can you help me please.
Screen Image: http://i53.tinypic.com/2ef2rtv.jpg
Best Regards.Im not creating blank message
i use the a term but the problem is, when i first hit save button and see the error message,than i hit enter button to pass the message and make the input fields editable again. But sy-ucomm is still equal to BU so it show the message again and again and i cant return to normal input screen. And if i make the message type 'S' i cant block the saving process.
I have to option first i will use type E message but i have to get over the problem above, or i will use type 'S' message but i have to stop the transaction after this message. I used type E like S or type S like E. They didnt work. -
Hi Friends,
I'm unable to decide whether to use user exits or badis. What does SAP recommend.
Example, if i want to add new tab in item details of PO...do i have to use badi or user exit and during PO creation if i want the to check a z tablUser Exit can be used only once , where as BADI can be used Multiple times..
basing on that take a decision.. -
User-exit that split at item level according to bill of entry(BOE)
HI,
need to write the logic for splitting invoices at item level according to BOE.
Customized new table:
Info for the customized table:
Table Name: ZIN_BONDINV
Field Name Data Element Type Length Short Text
MANDT MANDT CLNT 03 Client
VBELN VBELN_VF CHAR 10 Billing Document
EXNUM J_1IEXCNUM CHAR 10 BOE or Excise Invoice #
EXYEAR J_1IEXYEAR NUMC 04 Excise Year
ZEILE J_1IZEILE1 NUMC 04 Item no - GR at depot
ZVBELN VBELN_VL CHAR 10 Delivery Number
Z POSNR POSNR_VL CHAR 06 Delivery item
ZWERKS WERKS_D CHAR 04 Plant
This table to be used for storing the invoice created using delivery document along with other information extracted during billing document creation.
Logic for populating the table:
User Exit: RV60AFZC
Form: USEREXIT_FILL_VBRK_VBRP
This user exit should be used to update records in the customized table for the data with which billing document is created. The data should be populated as follows:
VBELN = VBRK-VBELN
EXNUM = J_1IRG23D-EXNUM*
EXYEAR = J_1IRG23D-EXYEAR*
ZEILE = J_1IRG23D-ZEILE*
ZVBELN = VBRP-VGBEL
ZPOSNR = VBRP-VGPOS
ZWERKS = VBRP-WERKS
*The above data is read during splitting the billing document based on BOE (copy control routine 602) and should be used from there.USER-EXIT NAME IS RV60AFZZ
-
User exits for delivery picking confirmation and transfer order creation
Hi
We have a scenario for which we need help.
This is to do with replenishment from plant to plant.
We have sales sets.
The sales sets needs to be replenished from one plant to another. We want the componenets of the sales sets to picked from the issuing plant. For this we need a transfer order. this needs tobe confirmed and then the goods issue should take place from the issuing plant. Its a two step process.
we are doing Sales sets in STO. The explosion takes place in STO. However when we create deliveries for this. Only the sales set header item without its components are flowing into the delivery.
The Tranfer order does not contain the components either.
However post the goods issue we can create a TO with reference to the TR. This is is not acceptable because we want the picking and confirmation to occur before PGI from the issuing plant.
Could anybody help: We want the TO to be created with the components even though in the delivery only the Sales set header appears. Can u suggest a user exit in which when we create the TR from the delivery the components of the set.
After confirmation of the TO then we want the picking status to be put as C.
SupreethHi,
Check the following users exits.
MWMRFSSG user exit for sorting TOs in RF system-guided transaction
MWMRFUP Customer defined general purpose pushbutton called from scr.
MWMRP001 Cust. Exit for Fixed Bin Replenish.: Delivery Item Selection
MWMRP002 Cust. Exit for Fixed Bin Replenishment: TR Quantity Distr.
MWMRP003 Customer Exit for Replenishment using RLLNACH1
MWMRP004 User Exit for Replenishment using RLLNACH4
MWMTO001 Enhancements for end of transfer order generation
MWMTO010 Exit: Calculation of Total Planned TO Processing Time
MWMTO011 Correction of Planned Processing Time for TO Item
MWMTO012 Correction of Sorting and Split Transfer Order
MWMTO013 Stock Removal for Sev. Storage Types as in Stringent FIFO
MWMTOAU3 Separate selection of posting changes for autom.TO creation
MWMTR001 Exits at the end of transfer rqmnt creation (IM,PP interf.)
MWMD0001 Transfer order print via RLVSDR40
MWMD0002 Transfer order print as multiple process with RLKOMM40
MWMIDI07 Enhancement for Output WMPIHU (Create Pick-HU) Inbound
MWMIDO11 Enhancement for message WMTORD: TO with several items
MWMIDO12 Enhancement for Output WMPIHU (Pick-HUs) Outbound
MWMIDO13 Extension for WMMBXY (subsequent tasks after goods movement)
MWMPP001 Enhancement WM/PP Interface (automatic TR generation)
Regards,
Murali
Maybe you are looking for
-
My Windows XP machine is set up following the accessibility options in Windows accessories...expanded text...large cursor and the High Contrast theme...with green text...black background...large icons and scrollbars. I use Windows Magnifier at the to
-
hello
-
Hello, How is it possible to extract data from a Lotus Notes database into SAP BW? Since I know too little about Lotus Notes, therefore my questions: Which way of extraction has to be chosen: UDC, or something else? Which kind of database is LN, mult
-
Multiple columns on same page?
I'm looking for a way to have a two column page layout, with three columns each that flows from page 1 column 1, to page 1 column 2, then to page 2 column 1 to page 2 column 2, etc. It's for a karaoke list and the columns are Song, Artist, and Song #
-
Urgent: Need a docking speaker with internal battery and suitable for ipad or iphone4
Need a docking speaker with internal battery and suitable for ipad or iphone4 Does the following model fit those requirements? Do you have any recommendation for me on a docking speaker? Philips - Fidelio Primo Docking Speaker for Apple® iPod® and i