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

Error message inside MB_DOCUMENT_BADI

Former Member
0 Likes
1,826

I want to give an error message inside MB_DOCUMENT_BADI,

It’s giving me a sort dump. How to raise an error message inside a BADI.

Pls help..this is Urgent

Regards,

Rajib Mahapatra

6 REPLIES 6
Read only

Former Member
0 Likes
999

Did you use the methode MB_DOCUMENT_BEFORE_UPDATE?

Regards,

John.

Read only

0 Likes
999

hi John,

Yes I am using .. MB_DOCUMENT_BEFORE_UPDATE

Regards,

Rajib.

Read only

Former Member
0 Likes
999

Hi,

Write like this....

If sy-subrc <> 0.

MESSAGE ID 'ZERR' TYPE 'E' NUMBER '191'

WITH 'Not updated'.

This will work.

Thanks.

Note: Reward Points if you find useful.

Read only

0 Likes
999

hi,

It's also giving dump.

Regards,

Rajib

Read only

0 Likes
999

Hi,

I am facing the same situation like Rajib. If anyone have a good solution for this please tell me.

Rajib,

If you have solved this problem please tell me how you did it.

Thanks.

Read only

0 Likes
999

Hi,

The dump is coming in the MB_DOCUMENT_BADI when we are trying giving any error message inside the BAID, because we are giving an error message inside an update task. So don’t use any error message inside this, but if your requirement is not satisfied by this, please try to use any other BADI like try with MB_CHECK_LINE_BADI.

It may be useful for you. Using this BADI my problem got resolved.

Thanks & Regards,

Rajib

Reward points if helpful