03-16-2007 12:53 PM
Hello!
How can I find out whether USER-EXIT is active or not ?
I set a break-point at these points and nothing happens
if I want save my daocument ???
Why
PERFORM USEREXIT_SAVE_DOCUMENT.
PERFORM USEREXIT_SAVE_DOCUMENT_PREPARE.
Ragards
Ilhan
03-16-2007 1:02 PM
Hi,
The user exits which you have given are standard ones.chek the program SAPMV45A and see..I don't think they are inactive...Plz chek the same....chek also the include....MV45AFZZ.
Regards,
Nagaraj
03-16-2007 1:02 PM
Hi,
Since these user exits are as apart of the Purchase order main program,
if you write the code and activate , that's enough, means the exit is active. You have to keep a break point and check at that point whether the code what you wrote for that exit is working or not.
But for most of other user exits, we have to create a project in CMOD T code and have to activate it. then only that code what we write in the fun module becomes effective. There is a scope for deactivation also in CMOD.
Hope this is useful.
Reward for useful answers.
Regards,
Anji
03-16-2007 1:13 PM
Hi Ilhan
The easiest way, I guess, is by going to transaction SMOD, sticking in your enhancement name and pressing the test button.
When placing breakpoints, don't use <b>Breakpoints > Breakpoint at > Statement...</b> and enter
PERFORM USEREXIT_SAVE_DOCUMENT
because you won't get any hits since the function module names are stored dynamically.
Rather use <b>Breakpoints > Breakpoint at > Function Module...</b> and enter
USEREXIT_SAVE_DOCUMENT
for a better chance of hitting the breakpoint.
Cheers
Lyal
Message's terrible grammar was edited by:
Lyal Schumann
03-16-2007 1:25 PM
... thank you bur what is the enhancement name for this
USER EXIT ???
Regards
Ilhan
03-16-2007 2:19 PM
There is no SMOD available for all the usereixts avaialbel in MV45AFZZ. These includes, USEREXIT_SAVE_DOCUMENT and USEREXIT_SAVE_DOCUMENT_PREPARE. Since there is <b>no SMOD</b>, there won't be any <b>CMOD project too.</b>
Look at the include program MV45AFZZ using SE38. Look for Form routines for these two user-exit. If you find any code written there, that means that these exists are used.
These user-exist triggers, any time any sales document ( inquiry, quotation, sales order, contract ect..) create or changed.
If these user-exits are not implemented yet in your system and you want to implement them, you will need access key for MV45AFZZ.
Let me know if you need any other information.
Regards,
RS
03-16-2007 2:36 PM
Hello RS!
Thank you very much for your declaration regarding User Exits by SD.
I have inserted this code fragment into the Form userexit_save_document.
At the point of where this FORM is performed I set a breakpoint and nothing has
happened
FORM userexit_save_document.
IF KUAGV-KUNNR EQ '9999999'.
VBKD-BSTKD = 'INITIAL'.
ENDIF.
ENDFORM
03-16-2007 2:39 PM
Hi Ilhan,
Where did you put your break point?
In the line <b>IF KUAGV-KUNNR EQ '9999999'.</b>
or on the line <b>VBKD-BSTKD = 'INITIAL'.</b>?
It will stop if you keep the breakpoint on the if statement.
Or hard code BREAK-POINT. in the form-endform section.
Regards,
Ravi
03-16-2007 2:54 PM
hello Ravi I put the break-point
on the
PERFORM USEREXIT_SAVE_DOCUMENT.
Regards
Ilhan
03-16-2007 3:07 PM
hello ravi it has stopped but this assignment with
literal 'INITIAL' hasn't been performed !
Waht is wrong?
Regards
Ilhan
03-16-2007 6:56 PM
Hi,
Do you want to pass "INITIAL' into VBKD-BSTKD or you want to clear it. If you want to clear it then you should write
<b>
CLEAR VBKD-BSTKD
</b>
But, if your requirement is to change data in table VBKD based on some condition, i would suggest you to use the user-exit USEREXIT_MOVE_FIELD_TO_VBKD instead. This is also a form routine inside include MV45AFZZ ( same include where USEREXIT_SAVE_DOCUMENT is there ). Also, if you want to clear the content the VBKD-BSTKD, write the code <b>
CLEAR VBKD-BSTKD.
</b>
Let me know if you have any question.
Regards,
RS