07-21-2008 12:47 PM
In transaction VF02, when i go to maintain the header text, if i do not maintain the header text , then at the time of saving the document i want to fire the exit so that the header text is always maintained. How do i do it for Header text.
07-21-2008 1:01 PM
Hi!
Use the program: RV60AFZZ
FORM USEREXIT_NUMBER_RANGE USING US_RANGE_INTERN.
if sy-tcode = 'VF02' and "Invoice change transaction ?
sy-ucomm = 'SICH'. "Save operation ?
* here you have to use READ_TEXT fm with
* object: VBBK
* ID: 0001 (maybe other if the text is in an another object)
* language: sy-langu
* name: vbrk-vbeln
* if the text does not exists, then create an message with SE91 (with name ZSD_ERROR)
* and then use the statement:
MESSAGE E001(ZSD_ERROR). "this will prevent saving
endif.
endif.
ENDFORM.
Regards
Tamá
07-21-2008 1:58 PM
I tried to put debugger at this point of code but when i run vf02 and go to save , it does not go into the debugger. So may be the code is also not executed.Please suggest how to solve .