Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 8419

USEREXIT_SAVE_DOCUMENT_PREPARE : For Validating Purchase Order

$
0
0

In VA01,  If the purchase order and purchase order item is blank then error message will be displayed for the user to input these values .

I have writtwen below code in MV45AFZZ,   USEREXIT_SAVE_DOCUMENT_PREPARE. The problem is that when purchase order or purchase order item is not entered, the field is greyed out . Please suggest

 

 

 

   If VBAK-BSTNK is initial.
  message e000(ZMSG).        " Enter Purchase Order
ELSE.
   Read table xvbap with key POSEX = ' '.
* If VBAP-POSEX is initial.
   IF sy-subrc = 0 .

       SHIFT xvbap-POSNR  LEFT DELETING LEADING '0'.
  message e001(ZMSG) with  xvbap-POSNR .                                  " In Order data Tab, Enter Purchase order item
ENDIF.

ENDIF.


Viewing all articles
Browse latest Browse all 8419

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>