Application Development 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: 

badi

Former Member
0 Kudos

Hi experts,

In the method MB_DOCUMENT_UPDATE , I created a FM for a requirement .

When I execute the transaction VLMOVE for testing, the MB_DOCUMENT_UPDATE method triggering two times , so my FM inside this executing two times .

What could be the problem? pls suggest. I implemented as shown below

1. In se18, In MB_DOCUMENT_BADI

2 . Clicking Implemention ->Change->Implementaion Name

3. Clicking the tab->interface->double click on method MB_DOCUMENT_UPDATE

4.Created FM inside the Method MB_DOCUMENT_UPDATE

Is there any mistake in implementaion? pls give suggestion

thanks

sai

1 ACCEPTED SOLUTION

former_member181995
Active Contributor
0 Kudos

This BADi would be trigger each time for each materail document posting.so may be in your case you have 2 document so it's triggering 2 times.

Amit.

7 REPLIES 7

former_member181995
Active Contributor
0 Kudos

This BADi would be trigger each time for each materail document posting.so may be in your case you have 2 document so it's triggering 2 times.

Amit.

0 Kudos

Hi Amit,

Thanks for the reply,but the material document are not the reason .

one material document contains 4 entries even though the method is triggering two times.

pls suggest

0 Kudos

set the counter in each itration in BADi once counter reach 2(means second time BADi triggered) than do nothing just bypass.

Amit.

0 Kudos

>>>2 . Clicking Implemention ->Change->Implementaion Name

Are u changing the existing implementation?

0 Kudos

Hi Kiran,

Yes I am changing the existing implementation. In that Implementation there is one FM already return.

Now I placed my FM below, That could be the reason?

0 Kudos

Hi Kiran,

I found the problem, I am written my FM in another implementation .

Now I created the new implementation and I place the FM in that implementation.

Now the new implementation ins inactive. When I try to activate in se19 i am getting below mentioned message. Now in the list of enhacement implementation, I don't see relevant implementation for my badi

now please let men know what to do?

Implementation ZZMB_DOCUMENT_BADI migrated (see long text for instructions)

Message no. SEEF_BADI049

Diagnosis

A BAdI was migrated. All existing implementations must now be migrated

as well.

Procedure

The new BAdI is now part of an enhancement spot, while the new BAdI implementation is part of an enhancement implementation. In the subsequent dialog box, you either have to create a new enhancement implementation or select an existing one.

Caution: Only select enhancement implementations that you are allowed to process. For example, a customer BADI implementation should never be migrated into an SAP enhancement implementation. If you do not find any suitable enhancement implementation, create a new one using the create button.

Former Member
0 Kudos

solved