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: 

Function module for the Inbound Delivery

Former Member
0 Kudos

Dear ABAPers,

I have created the Inbound Delivery in VL01N Transaction.I want to create the Post goods issue for the Delivery number.What is the Function module for the Post goods issue for the Delivery number and what all the Parameter needs to be passed.

Thanks & Regards,

Ashok.

1 ACCEPTED SOLUTION

former_member480923
Active Contributor
0 Kudos

Use the Function Module MB_CREATE_GOODS_MOVEMENT. Pass the Delivery number as the reference document (XBLNR) in MKPF and pass table I_MSEG (called_by = VL02N and BWART = 601).

Hope That Helps

Anirban M.

4 REPLIES 4

former_member480923
Active Contributor
0 Kudos

Use the Function Module MB_CREATE_GOODS_MOVEMENT. Pass the Delivery number as the reference document (XBLNR) in MKPF and pass table I_MSEG (called_by = VL02N and BWART = 601).

Hope That Helps

Anirban M.

Former Member
0 Kudos

Hi

Use FM MB_POST_GOODS_MOVEMENT for PGI .

I am sure it will be useful .

Give xblnr as input .

Regards,

Ramya

Former Member
0 Kudos

Hi,

Try this code...

PARAMETERS: p_vbeln LIKE likp-vbeln OBLIGATORY.

DATA: l_vbkok_wa TYPE vbkok,

l_i_prott TYPE STANDARD TABLE OF prott,

l_pgi_status TYPE xfeld,

c_check TYPE c VALUE 'X'.

l_vbkok_wa-vbeln_vl = p_vbeln.

l_vbkok_wa-vbtyp_vl = 'T'.

l_vbkok_wa-wabuc = c_check.

  • Do PGI

CALL FUNCTION 'WS_DELIVERY_UPDATE'

EXPORTING

vbkok_wa = l_vbkok_wa

commit = c_check

delivery = l_vbkok_wa-vbeln_vl

IMPORTING

ef_error_in_goods_issue_0 = l_pgi_status

TABLES

prot = l_i_prott.

IF l_pgi_status IS NOT INITIAL.

  • WRITE:/ 'PGI Failure : ', p_vbeln.

ELSE.

  • WRITE:/ 'PGI Success : ', p_vbeln.

CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'

EXPORTING

wait = c_check.

ENDIF.

Regards

Meenakshi

0 Kudos

Dear All,

Thanks for all your reply.Your Answers solved my problem.

Thanks & Regards,

Ashok.