Skip to Content
author's profile photo Former Member
Former Member

Creating new sales-order item with text using BAPI_SALESORDER_CHANGE

Hi all.

I want to create new sales-order item in an existing sales-order by using BAPI_SALESORDER_CHANGE. This works fine.

I also want to enter item-texts for the new item in the same call, but this doesn't work.

When I call the BAPI I do not assign an item-number for the new item, thus I have no item-number to assign to ITM_NUMBER in table ORDER_TEXT. IF ITM_NUMBER is empty, it's treated as a header text....

Any clues?

Regards

/Elisabet

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Aug 13, 2008 at 08:15 AM

    If you use BAPI_SALESORDER_CHANGE in simulate mode first, does it returns you the item numbers? If so, use these when calling the bapi for the second time (update mode).

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Aug 13, 2008 at 08:51 AM

    increment the last itemnumber and pass it to that.

    if they are following a sequence 10,20,30.

    find the next sequence and send it to the ITEMNUMBER field.

    or else you add the text after the Function call.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.