on 05-09-2006 7:59 PM
Hi,
I have written an user exit (program 'MV45AFZZ') ( user exit 'FORM USEREXIT_SAVE_DOCUMENT_PREPARE'). Here I want to give an error message (before save the doc) if the user did not enter the correct order reason. It is giving error message properly, but during the message, system is showing all the fields (VA01) in display mode.After displaying the error message when user press enter system should be able to show Order Reason field as input parameter not display parameter. Pls suggest how to handle this situation. Code is given below :
-
if xvbak-auart = 'ZFRE'.
IF XVBAK-VKORG = TVAUK-VKORG AND
XVBAK-VTWEG = TVAUK-VTWEG AND
XVBAK-SPART = TVAUK-SPART AND
XVBAK-AUDAT GT TVAUK-DATAB.
if xvbak-augru ne tvauk-augru.
SET CURSOR FIELD 'VBAK-AUGRU'.
message E000(zsd01) with
'Please select correct Order Reason'.
exit.
endif.
ELSE.
SET CURSOR FIELD 'VBAK-AUGRU'.
message e000(zsd01) with
'Please select correct Order Reason'.
ENDIF.
ELSE.
if xvbak-augru eq tvauk-augru.
SET CURSOR FIELD 'VBAK-AUGRU'.
message E000(zsd01) with
'Please select Order Reason not assigned to Cost Center'.
endif.
ENDIF.
-
Thanks,
Pradeep
Hi,
Try to use user exit FORM USEREXIT_CHECK_VBAK USING US_DIALOG from include MV45AFZB.
regards
Krzys
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
8 | |
4 | |
3 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.