Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

ME21n Document date Validation

raviram_jk
Explorer
0 Likes
582

Dear Experts,

My requirement was that ME21n document date should always equal to creation date or system date.

how to achieve this validation in ME21n . is there any BADI or Enhancement for this

Regards

ravi.

1 REPLY 1
Read only

RaymondGiuseppi
Active Contributor
0 Likes
493

Yes, try to use ME_PROCESS_PO_CUST, there you could either:

  • Force data (with  im_header->get_data and set_data) you can execute those function in PROCESS_HEADER as well as CHECK (execute at least once before SAVE) and even in OPEN method.
  • Raise an error message:  Include mm_messages_mac, and use mmpur_metafield (mmmfd_doc_date for BLDAT) and mmpur_message_forced to raise an error on field document date followed by im_header->invalidate

Use search tool, many threads and document are already posted on this BAdI.

Regards,

Raymond