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: 

Not able to modify value in field MKPF-XBLNR (material document- reference field)

Former Member
0 Kudos

Hello,

when we are doing goods receipt for the inbound delivery in T code VL32n, Inbound delivery is created for a Purchase order. when GR is done,  the material document is created. In the material document  in header level we have the "reference number field". In this field (MKPF-XBLNR), by default, the inbound delivery number is populated.


we want to over ride the inbound delivery number in field MKBF-XBLNR with some other value from Purchase order. Issue is as follows.

material document is created by standard SAP through standard FM  "MB_POST_GOODS_MOVEMENT ". we are using a BADI " LE_SHP_GOODSMOVEMENT " to fetch value from PO (purchase order). we are passing this PO value to MKPF-XBLNR but when this FM "MB_POST_GOODS_MOVEMENT " is called, this FM is again over writing  our new value with the original value (i.e. inbound delivery number ).

what is to be done so that FM does not over write the old value ?

regards

Pamela

2 REPLIES 2

Former Member
0 Kudos

Pamela,

I haven't checked when/why the over write happens but if this badi does not help, you can work with the badi MB_DOCUMENT_BADI. The method MB_DOCUMENT_BEFORE_UPDATE gets called before the update happens and the method MB_DOCUMENT_UPDATE gets called after commit.

Thanks,

Vikram.M

Former Member
0 Kudos

Hi Pamel,

May be try not to pass the xblnr value to fm MB_POST_GOODS_MOVEMENT.
Can you show us how you have called these both fms. Then we will be able to understand your problem.

regards,

Pranav.