BAPI For Delivery
Hi,
Can someone tell the BAPI which can be used to create the Delivry in reference to Shipping Point,Sales Order,Item Number?
Please its urgent,
Thanks,
Shashi Devi.
Hi
Devi,
* Include YCL_CREATE_DELIVERY_DOCU
* Form delivery_creation *
* This Subroutine is used to Create Delivery
FORM delivery_creation .
CONSTANTS:
LC_DOCU_TYPE type
LESHP_DOCUMENT_TYPE value 'A'. " Document Type.
DATA:
BEGIN OF LFS_vbap,
vbeln TYPE vbap-vbeln, " Sales Document
posnr TYPE vbap-posnr, " Sales Document Item
kwmeng TYPE vbap-kwmeng, " Order quantity in sales units
matnr TYPE vbap-matnr, " Material Number
werks TYPE vbap-werks, " Plant
END OF lfs_vbap.
DATA: lw_delnum type VBELN. " To store delivery number.
* LOCAL TABLES DECLARATION *
DATA:
Lt_VBAP LIKE TABLE OF Lfs_VBAP, " To Store datata from vbeln..
lt_request TYPE STANDARD TABLE
OF bapideliciousrequest, " Data for Creating Deliveries
lt_created TYPE STANDARD TABLE OF bapideliciouscreateditems,
" To Store Delivery Item..
lt_return TYPE STANDARD TABLE OF bapiret2.
" Table for Return Parameters
* LOCAL FIELD STRINGS DECLARATION *
DATA:
lfs_request type bapideliciousrequest,
" Work area for lt_request
lfs_created like line of lt_created,
" Work area for lt_created
lfs_return like line of lt_return.
* To get required values from VBAP
SELECT vbeln
posnr
kwmeng
matnr
werks
INTO TABLE Lt_vbap
FROM vbap
WHERE vbeln = W_vbeln.
if sy-subrc ne 0.
write / text-002.
exit.
endif. " if sy-subrc ne 0
LOOP AT Lt_vbap INTO LFS_VBAP .
lfs_request-document_numb = lfs_vbap-vbeln.
lfs_request-document_item = lfs_vbap-posnr.
lfs_request-quantity_sales_uom = lfs_vbap-kwmeng.
lfs_request-id = 1.
lfs_request-document_type = LC_DOCU_TYPE.
lfs_request-delivery_date = sy-datum.
lfs_request-material = lfs_vbap-matnr.
lfs_request-plant = lfs_vbap-werks.
lfs_request-date = sy-datum.
lfs_request-goods_issue_date = sy-datum.
lfs_request-goods_issue_time = sy-uzeit.
APPEND lfs_request to lt_request.
ENDLOOP. " Loop at lt_vbap
CALL FUNCTION 'BAPI_DELIVERYPROCESSING_EXEC'
TABLES
request = lt_request
createditems = lt_created
return = lt_return.
Read table lt_created into lfs_created index 1.
if lfs_created-DOCUMENT_NUMB is initial.
loop at lt_return into lfs_return .
write / lfs_return-message.
write : / text-004.
endloop. " Loop at lt_return
ELSE.
perform commit_work. " To Call External Commit
lw_delnum = lfs_created-document_numb.
FS_DISP-TEXT = TEXT-001.
FS_DISP-NUMBER = LW_DELNUM.
APPEND FS_DISP TO IT_DISP.
if p_torder eq c_x or p_pgi eq c_x or p_bill eq c_x.
perform transfer_order using lw_delnum.
" TRANSFER ORDER CREATION
endif. " If p_torder eq 'X'
ENDIF. " If sy-subrc eq 0
ENDFORM. " Delivery_creation
This is the code that using BAPI to create delivery document
<REMOVED BY MODERATOR>
<REMOVED BY MODERATOR>
Edited by: Alvaro Tejada Galindo on Jan 11, 2008 5:21 PM
Similar Messages
-
BAPI for delivery doc creation required
Hi All,
I need to develop a program wherein I need to create a sales order, delivery order, PGI(post goods issue) and invoice.......I have identified the bapi for sales order creation as bapi_sales_order_create..
I request u to kindly help with the others....lemme know the relevant bapis for the others...Hi,
Chk the FM's given below..Hope this will help you...
BAPI For Delivery Order
BAPI_DELIVERYPROCESSING_EXEC
BAPI to post a Goods issue
BAPI_OUTB_DELIVERY_CONFIRM_DEC "inbound Delivery
Filling HEADEWR_DATA-DELIV_NUMB, HEADER_CONTROL-DELIV_NUMB, DELIVERY with the delivery number and HEADER_CONTROL-POST_GI_FLG with 'X' does the job.
BAPI_OUTB_DELIVERY_CONFIRM_DEC " outboung Delivery
Reward Points if helpful.
Regards,
Harini.S -
Bapi for Delivery Creation from Sales Order
Hi
I have multiple sales order and i want to create 1 outbound delivery from it just like what Vl10A is doing.
Can i have BAPI or fumctiona module for same.
Best Regards
SubhamCheck this thread:BAPI for Delivery Creation
Also search the forums..there are many threads addressing the same issue.
Regards,
Kiran -
Hi Experts!
Can anyone tell me the BAPI to Display the Delivery Status
for a particuler sales order no or document no.
Thank U...hi,
BAPI_DELIVERYFREE_PROXY_CREATE Proxy BAPI für Upload einer kostenlosen Nachlieferug SFA-Kontext: Anle
LE_SHP_DB_DELIVERY_BUFFER Object Buffer Delivery w/Database Access
BAPI_DELIVERY_GETLIST BAPI for Reading Delivery Data
OIU_DELIVERY_NETWORK Object Buffer Delivery w/Database Access
BAPI_DELIVERY_NETWORK_CHANGE Delivery Network BAPI for Changes
BAPI_DELIVERY_NETWORK_CREATE BAPI for creating a delivery network
BAPI_DELIVERY_NETWORK_READ Display delivery network details
BAPI_INB_DELIVERY_CHANGE
BAPI_INB_DELIVERY_CONFIRM_DEC BAPI for Inbound Delivery Verification from a Decentralized System
BAPI_INB_DELIVERY_SAVEREPLICA BAPI Function Module for Replication of Inbound Deliveries
BAPI_OUTB_DELIVERY_CHANGE
BAPI_OUTB_DELIVERY_CONFIRM_DEC BAPI for Outbound Delivery Confirmation from a Decentralized System
BAPI_OUTB_DELIVERY_CREATENOREF Generates Delivery Without Reference
BAPI_OUTB_DELIVERY_CREATE_SLS Generates Delivery for Customer Order
BAPI_OUTB_DELIVERY_CREATE_STO Generates Delivery for Stock Transport Order
BAPI_OUTB_DELIVERY_SAVEREPLICA BAPI Function Module for Replication of Outbound Deliveries
BAPI_OUTB_DELIVERY_SPLIT_DEC BAPI for Subsequent Outbound-Delivery Split from a Decentralized Syste
and for "Shipment
BAPI_SHIPMENT_CHANGE Change Shipment
BAPI_SHIPMENT_COST_ESTIMATE Calculate Shipment Costs of Different Forwarding Agents for Shipment
BAPI_SHIPMENT_CREATE Create Shipment -
BAPI for delivery VL01N transaction
Hi All,
I am working on SAP ECC 5.0 version. My requirements are to create a delivery note against a purchase order. The purchase order is basically for Stock transfer between intra company (UB) and Inter Company (NB) . So am looking for BAPI that can create outbound delivery for Goods movement types 641 and 643.
I tired searching some of the already asked questions on this forum, but nothing was substantial.
If any of you know the BAPI/ worked on similar requirements, Please let me know the details with an example snippet if possible.
Thanks,
KiranHI,
check this link BAPI for Outbound Delivery Creation with reference to Sales Order - VL01N
Thanks
Mahesh -
FM/BAPI for delivery creation
Hi,
I need to create a delivery w/o order reference though VL01N0 ,but i am unable to find any BAPI / FM which could let me do so through the code w/o BDC.
Can any one suggest a FM/BAPI for the same.
KunalHi kunal,
You can use BAPI BAPI_DELIVERYPROCESSING_EXEC to deliver preceding documents like a sales order.
If this doesn't solve ur recquirement then write an BDC Program .
I have done some BDC programs On VL01n before...u will not face any problem .
ravinder. -
Hi ,
Please suggest me any BAPI for updating the delivery document header.
Thanks.
Regards
DVHi
This is a BAPI code, go thru this, hope it wil help you.
reward if help.
Check this sample program for creating delivery from a sales order.
Give the sales order as input..
PARAMETERS: p_vbeln LIKE vbak-vbeln.
DATA: BEGIN OF t_vbap OCCURS 0,
vbeln LIKE vbap-vbeln,
posnr LIKE vbap-posnr,
kwmeng LIKE vbap-kwmeng,
matnr LIKE vbap-matnr,
werks LIKE vbap-werks,
END OF t_vbap.
DATA: t_request TYPE STANDARD TABLE OF bapideliciousrequest
WITH HEADER LINE.
DATA: t_created TYPE STANDARD TABLE OF bapideliciouscreateditems
WITH HEADER LINE.
DATA: t_return TYPE STANDARD TABLE OF bapiret2 WITH HEADER LINE.
SELECT vbeln posnr kwmeng matnr werks
INTO TABLE t_vbap
FROM vbap
WHERE vbeln = p_vbeln.
LOOP AT t_vbap.
t_request-document_numb = t_vbap-vbeln.
t_request-document_item = t_vbap-posnr.
t_request-quantity_sales_uom = t_vbap-kwmeng.
t_request-id = 1.
t_request-document_type = 'A'.
t_request-delivery_date = sy-datum.
t_request-material = t_vbap-matnr.
t_request-plant = t_vbap-werks.
t_request-date = sy-datum.
t_request-goods_issue_date = sy-datum.
t_request-goods_issue_time = sy-uzeit.
APPEND t_request.
ENDLOOP.
CALL FUNCTION 'BAPI_DELIVERYPROCESSING_EXEC'
TABLES
request = t_request
createditems = t_created
return = t_return
READ TABLE t_return WITH KEY type = 'E'.
IF sy-subrc = 0.
MESSAGE e208(00) WITH 'Delivery creation error'.
ENDIF.
COMMIT WORK.
READ TABLE t_created INDEX 1.
WRITE: / 'Delivery - ', t_created-document_numb. -
hi,
1.can i create delivery for particular customer using bapis?
2.can i create invoice using bapis?
if it is possilble pls tell me the bapi names??????????????
regards
GuruHi Guruvulu,
Take a look at the following ones :
BAPI_INB_DELIVERY_CHANGE Change inbound delivery
BAPI_INB_DELIVERY_CONFIRM_DEC BAPI for inbound delivery verification from a decentralized system
BAPI_INB_DELIVERY_SAVEREPLICA BAPI Function Module for Replication of Inbound Deliveries
BAPI_OUTB_DELIVERY_CHANGE BAPI for Change to Outbound Delivery
BAPI_OUTB_DELIVERY_CONFIRM_DEC BAPI for Outbound Delivery Verification from a Decentralized System
BAPI_OUTB_DELIVERY_SAVEREPLICA BAPI Function Module for Replication of Outbound Deliveries
BAPI_OUTB_DELIVERY_SPLIT_DEC BAPI for Subsequent Outbound-Delivery Split from a Decentralized Sys
<b>BAPI_OUTB_DELIVERY_SAVEREPLICA / BAPI_INB_DELIVERY_SAVEREPLICA should be ok for you for the delivery creation.
and BAPI_INCOMINGINVOICE_CREATE for invoice.</b>
Hope this helps,
Erwan -
FM or BAPI for Delivery Order Picking and PGI
Good day,
I would like to check with you all on any function module or BAPI which can perform delivery order picking and PGI ?
I did some research and found that a lot of people is introducing this FM "WS_DELIVERY_UPDATE_2"
but i'm not sure how this FM works. Can anyone provide some information for me on this function like what data to propagate into this FM and etc... ?hi,please check this link.
Need to update picking,packing and PGI using FM "WS_delivery_update"
also,
for picking: WS_DELIVERY_UPDATE_2
pgi : BAPI_GOODSMVT_CREATE
thanks. -
Hi,
There is a structure for EXTENSION1 & EXTENSION2 in the bapi's BAPI_OUTB_DELIVERY_CHANGE & BAPI_DELIVERYPROCESSING_EXEC.
How that will help to update lips. I have created custom fields in LIPS . Will these structures help to update LIPS ?
Thankshave you tried the below bapi? were they use ful
BAPI_INB_DELIVERY_CHANGE - Change inbound delivery
BAPI_INB_DELIVERY_CONFIRM_DEC - for inbound delivery verification from a decentralized system
BAPI_INB_DELIVERY_SAVEREPLICA - Function Module for Replication of Inbound Deliveries
BAPI_OUTB_DELIVERY_CHANGE - for Change to Outbound Delivery
BAPI_OUTB_DELIVERY_CONFIRM_DEC - for Outbound Delivery Verification from a Decentralized System
BAPI_OUTB_DELIVERY_SAVEREPLICA - Function Module for Replication of Outbound Deliveries -
BAPI For Delivery n Batch Splits
Hi,
I need to do the Batch Splits on the delivery using a BAPI.
Can someone send me the name of the relevant BAPI?
Thanks,
Shashi Devi.thanks for the help
-
Function Module (BAPI) for Delivery Change
Dear All,
We have a Function Module "BAPI_SALESORDER_CHANGE" for changes in sales order, wherein we also can enter Texts in sales order.
Please tell me similar such function module for Outbound Delivery, wherein I can enter / insert / change the Texts (both Header & Item) in a deivery document.
Regards,
DhananjayThanks
Where in this Function Module do I find the table / parameter for adding text at item & header level.
Regards
Dhananjay -
Hello Guru,
i am looking bapi for delivery process (VL01n) in SD module.
i searched in bapi transaction, i can't find any relevant bapi for delivery process.
Regards,
ArasukumarHi,
Kindly refer the below link.
Re: BAPI for Delivery Creation
May be useful for you. Else reply back.
Regards,
Vijay V -
Hi all,
I am looking for a FM/ BAPI for Delivery Confirmation through transaction O4H1.
I have been able to achieve my result through FM OIKDC_DELIVERY_CONFIRM but this FM is not released. I am looking for a released FM / BAPI.
Points will be rewarded for helpful answers.
Regards,
MayankHi Mayank.
You can use fucntion 'OIGI_DEL_CONF_CREATE'.
Maybe, you work in IS-OIL or Gas..._
I hope this will help you.
good luck
Regards
Kyung Woo. -
Help Rgd. BAPI for Creation of Inbound delivery Document
Hi all,
I need a Bapi to create inbound delivery document without using PO reference. I have seen the below BAPIs. i) BAPI_IBDLV_CREATE_FROM_OBDLV,
ii) BAPI_GOODSMVT_CREATE. I am not sure whether they are for creating inbound delivery document without using PO reference.
It will be of great use if anyone can give me the BAPI for the purpose and the mandatory parameters or sample test data for the BAPI.
Thanks in Advance,
Rakesh.If you create the inbound delivery->check the purchase order in the tabstrip "Confirmations" on item level. There are three fields: "Confirmation control key", "Order acknowl." and "acknowl. required".
Ckeck if there is a value in "confirmation control key".
You should get the same error if you try to create VL31N in dialog mode, not only by using the bapi.
Rgds,
JP
Maybe you are looking for
-
Airport Express not recognized by Utility after changing security setting.
We use an Extreme with an Express to extend the network and run speakers. While trying to eradicate Airtunes dropouts I changed the security setting on the Express using the Airport Utility. After the update, the Express is no longer being recognized
-
Whats the use of table TBD05?
Hi.. I want to know the exact use of table TBD05 (Distribution model for message types).. And what shall I do to maintain the values in this table.? I am facing a problem when I am trying to create an IDOC with ALE as a medium.When I dubugged the cod
-
I have a MacBook running system 10.7.5 and Safari 6.1.6. When I try to load any page that has Flash content it freezes and becomes unresponsive to scrolling, etc. I have uninstalled Flash, the page loads OK but where the Flash content is supposed to
-
[locked] how to handle Machii_config_mode
Hi experts... can u pls help its very urgent.... can u pls tell me how to work with MACHII_CONFIG_MODE
-
How do I edit base w/o changing the others?
Is it possible to set a color in a theme as the base without changing the others? thx Andrew