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

BAPI_SALESORDER_CHANGE

Former Member
0 Likes
528

Hi All,

I am trying to add a line item to a Sales Order using BAPI_SALESORDER_CHANGE (from exit USEREXIT_SAVE_DOCUMENT of SAPMV45A prog).

When I execute the the BAPI separately with my parameters it works fine, but from my code in the USEREXIT or even from a test report program, I am unable to append the line item.

I am effectively passing just mat. no., item categ. and qty., using salesdocument, order_header_inx, order_item_in, order_item_inx, return parameters of BAPI. Also tried passinf schedule lines. But no go.

Please advice if I am missing soemthing. Please help.

Thanks.

3 REPLIES 3
Read only

Former Member
0 Likes
475

If you are trying to add line item in the sales order which you are currently processing, don't use BAPI, add the line item by filling the related structures in the routine "USEREXIT_SAVE_DOCUMENT_PREPARE" of MV45AFZZ.

Regards

Vinod

Read only

ThomasZloch
Active Contributor
0 Likes
475

Please stop posting duplicate threads!

Thomas

Read only

former_member772790
Participant
0 Likes
475

Does the user exit saved in a project or not. If not save it in a project and acivate it. And then test it.