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

BADI -MRM_HEADER_CHECK implementation - MIRO - error MESSAGES TAB ??

Former Member
0 Likes
5,104

Hi All,

I implemented classic BADI- MRM_HEADER_CHECK to raise custom error message(type E) validation for Reference(XBLNR) and append error message using MRM_PROT_FILL and the error message appeared in MESSAGES tab of MIRO transaction.

However, if I have ONLY this custom error in MESSAGES tab and try to post the LIV document system let it post successfully. Usually system should return the "Invoice still has messages" if any error(type E) appear in MESSAGES tab and shouldn't allow posting.

Do i need to add more code in my MRM_HEADER_CHECK implementation ?? to ensure sytem recognizes my custom error message and shouldn't allow posting ??

Regards,

Sri,

Hi All,

I implemented classic BADI- MRM_HEADER_CHECK to raise custom error message(type E) validation for Reference(XBLNR) and append error message using MRM_PROT_FILL and the error message appeared in MESSAGES tab of MIRO transaction.

However, if I have ONLY this custom error in MESSAGES tab and try to post the LIV document system let it post successfully. Usually system should return the "Invoice still has messages" if any error(type E) appear in MESSAGES tab and shouldn't allow posting.

Do i need to add more code in my MRM_HEADER_CHECK implementation ?? to ensure sytem recognizes my custom error message and shouldn't allow posting ??

Regards,

Sri,

4 REPLIES 4
Read only

Former Member
0 Likes
3,178

Check this thread in which Pablo Casamayor uses field symbol call stack technique (to retrieve values from main program memory) and use it to not allow saving in MIRO if there are still error messages.

Another problem also may arise that even if user corrects the invoice document still custom message may still show in the message log, for that issue also the post by Pablo clarifies.

[Pablo Casamayor's solution to MIRO messages problem with BADI: MRM_HEADER_CHECK |;

Read only

nabheetscn
SAP Champion
SAP Champion
0 Likes
3,178

There is also an exeption in the method HEADERDATA_CHECK also raise that exception ERROR after filling the error data.

Nabheet

Read only

nabheetscn
SAP Champion
SAP Champion
0 Likes
3,178

After filling the relevant error message raise the exception ERROR which is there in HEADERDATA_CHECK method.

In this way it will display message also and will not save

Nabheet

Read only

nabheetscn
SAP Champion
SAP Champion
0 Likes
3,178

There is also an exeption in the method HEADERDATA_CHECK also raise that exception ERROR after filling the error data.

Nabheet