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 Implementation : Declaration type automatically changes

0 Likes
1,177

I'M trying to implement a classic badi to divide 2 numbers. While defining methods i gave 2 importing parameters and 1 exporting parameter. While activating this BADI a popup displays that Interface for BAdI definition is not valid and changes will be made. The declaration type of 'exporting' parameter changes to 'changing' parameter which gives me a run time error while calling the method in SE80 program. Ss for references attached.

capture.pngq3-5.pngcapture.png

1 ACCEPTED SOLUTION
Read only

sergei-u-niq
Active Contributor
1,084

well, if it is a changing parameter now, use changing when calling badi:

Call badi ... ( ... 
changing e_result ).

PS: in case of modern BADIs, you can use exporting/returning only if it is a single-use BADI. if several BADI implementations can be called after oneanother (multiple use), then only CHANGING parameters can be used to "produce the result".

It's a very long time ago I defined a classic BADI (did I ever? if I did, then only for excercise purpose), but assume that something very similar is happening here.

1 REPLY 1
Read only

sergei-u-niq
Active Contributor
1,085

well, if it is a changing parameter now, use changing when calling badi:

Call badi ... ( ... 
changing e_result ).

PS: in case of modern BADIs, you can use exporting/returning only if it is a single-use BADI. if several BADI implementations can be called after oneanother (multiple use), then only CHANGING parameters can be used to "produce the result".

It's a very long time ago I defined a classic BADI (did I ever? if I did, then only for excercise purpose), but assume that something very similar is happening here.