‎2010 Mar 31 7:12 AM
Hi All,
When creating a shipment from VT01N I am trying to update the partner function field values
PARTNER TYPE (PARVW) and PARTNER under the Partner tab from BADI - BADI_LE_SHIPMENT in SAVE method.
So I am passing
ls_new_vbpa-kunnr = partner
ls_new_vbpa-parvw = partner type
and updating/entering new record with these values to into CHA_SHIPMENTS_AT_SAVE-NEW_VBPA.
But some reason BADI is not updating values in the table (not creating record in table VTPA)
Can anyone tell me the reason? Thanks for your time.
Thanks.
‎2015 Feb 06 4:29 PM
Hi Murali, the solution is when you fill the data in the structure cha_shipments_at_save-new_vbpa[].
Make sure to fill the field UPDKZ with an 'I' or 'U' before appending the information.
"insert or update flag
w_vbpa-mandt = sy-mandt. " Client
w_vbpa-vbeln = fp_w_vttk-tknum. " Shipment
w_vbpa-parvw = l_c_char_sp. " Partner
w_vbpa-lifnr = fp_w_vttk-tdlnr. " Fordwaring Agent (in my case)
w_vbpa-updkz = l_c_i. " Insert entry in table.
APPEND w_vbpa TO cha_shipments_at_save-new_vbpa[].
Best regards.
Nicolas.