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_INB_DELIVERY_CHANGE

Former Member
0 Likes
2,734

Hi!

I would like to delete an item (for example item 010) in an outbound delivery (VL02N). I found BAPI_INB_DELIVERY_CHANGE but i don't manage to use it.

In HEADER_DATA i key the delivery.

IN DELIVERY i key the delivery too.

In ITEM_DATA i key the delivery and the item.

in ITEM_CONTROL i key the item number (10)

But it doesn't work!

Could you help me please?

Thanks by advance,

LB

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
2,319

HI

Use this BAPI V50I BAPI_OUTB_DELIVERY_CHANGE for outbound delivery

the one which u have used is for inbound

Regards

Shiva

Hi!

I would like to delete an item (for example item 010) in an outbound delivery (VL02N). I found BAPI_INB_DELIVERY_CHANGE but i don't manage to use it.

In HEADER_DATA i key the delivery.

IN DELIVERY i key the delivery too.

In ITEM_DATA i key the delivery and the item.

in ITEM_CONTROL i key the item number (10)

But it doesn't work!

Could you help me please?

Thanks by advance,

LB

8 REPLIES 8
Read only

Former Member
0 Likes
2,320

HI

Use this BAPI V50I BAPI_OUTB_DELIVERY_CHANGE for outbound delivery

the one which u have used is for inbound

Regards

Shiva

Read only

0 Likes
2,319

thanks you for your answer!

It still doesn't work. Th return table is empty but the item is not deleted. Here is my code:


DATA g_delivery     TYPE bapiobdlvhdrchg-deliv_numb.
DATA gt_header_data TYPE TABLE OF bapiobdlvhdrchg WITH HEADER LINE.
DATA gt_header_ctrl TYPE TABLE OF bapiobdlvhdrctrlchg WITH HEADER LINE.
DATA return         TYPE TABLE OF bapiret2 WITH HEADER LINE.
DATA gt_data        TYPE TABLE OF  bapiobdlvitemchg WITH HEADER LINE.
DATA gt_ctrl        TYPE TABLE OF bapiobdlvitemctrlchg WITH HEADER LINE.


CLEAR g_delivery.
g_delivery = '0080000469'.

CLEAR   gt_header_data.
REFRESH gt_header_data.
gt_header_data-deliv_numb = g_delivery.
APPEND gt_header_data.

CLEAR gt_header_ctrl.
REFRESH gt_header_ctrl.
gt_header_ctrl-deliv_numb = g_delivery.
APPEND gt_header_ctrl.

CLEAR gt_data.
REFRESH gt_data.
gt_data-deliv_numb = '0080000469'.
gt_data-deliv_item = '000010'.
APPEND gt_data.

REFRESH gt_ctrl.
gt_ctrl-deliv_numb = '0080000469'.
gt_ctrl-deliv_item = '000010'.
gt_ctrl-del_item   = 'X'.
APPEND gt_ctrl.

CALL FUNCTION 'BAPI_OUTB_DELIVERY_CHANGE'
  EXPORTING
    header_data    = gt_header_data
    header_control = gt_header_ctrl
    delivery       = g_delivery
  TABLES
*    item_data      = gt_data
    item_control   = gt_ctrl
    return         = return.

Is there something wrong?

LB

Read only

0 Likes
2,319

After the call to FM BAPI_OUTB_DELIVERY_CHANGE, try to call the BAPI

BAPI_TRANSACTION_COMMIT for commiting the data to DB.

Hope this helps.

Thanks,

Balaji

Read only

0 Likes
2,319

Try using this FM LEINT_DELIVERY_CHANGE

regards

Shiva

Read only

0 Likes
2,319

It works with BAPI_TRANSACTION_COMMIT !

Thank you a lot for your help!

LB

Edited by: Laurent BOUDART on Mar 14, 2008 2:02 PM

Read only

0 Likes
2,319

Hi LB,

Can you close the thread if your issue has been resolved?

Reward points for all helpful answers.

Thanks,

Balaji

Read only

0 Likes
2,319

it is written "Your question is answered. " so i guess the thread is closed.

LB

Read only

Former Member
0 Likes
2,319

The BAPI you are using changes only inbound deliveries which can be changed via VL32N transaction.

So try BAPI_OUTB_DELIVERY_CHANGE for changing outbound delivery change.

Hope it helps.

Thanks

Balaji