cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Question regarding Delivery-BADI LE_SHP_DELIVERY_PROC (DELIVERY_FINAL_CHECK)

master1980
Explorer
0 Kudos
542

In the Method IF_EX_LE_SHP_DELIVERY_PROC~DELIVERY_FINAL_CHECK we have to populate the Protocol (CT_FINCHDEL). During Creation of a Delivery (e.G. VL01N) a Deliverey-Number (VBELN) has not Jet been created and is empty.

in VL01N this is not a problem but what about a Mass-Processing (e.g. VL10A) or a Bapi-Call in Z-Programms? In this case in IF_EX_LE_SHP_DELIVERY_PROC~DELIVERY_FINAL_CHECK there might be more than 1 Delivery-Header (VBELN) . In this case we have to fill CT_FINCHDEL with different keys (VBELN) in order the system to find the correct assignment Delivery-Message?

How to foll the CT_FINCHDEL-VBELN Correctly?

 

 

Accepted Solutions (0)

Answers (1)

Answers (1)

RaymondGiuseppi
Active Contributor
0 Kudos

In the implementing class you have to loop at header and item such as 

 

method if_ex_le_shp_delivery_proc~delivery_final_check .

  field-symbols: <ls_xlikp> type likpvb,
                 <ls_xlips> type lipsvb.

  " some code
  loop at it_xlikp assigning <ls_xlikp>.
    " some code at header level
    loop at it_xlips assigning <ls_xlips>
       " some code at item level

       " A message in the log delivery from saving)
       clear ls_finchdel.
       ls_finchdel-vbeln    = <ls_xlikp>-vbeln.
       " other fields
       insert ls_finchdel into table ct_finchdel.

    endloop.
  endloop.

endmethod.

 

master1980
Explorer
0 Kudos
Thank you, in VL01N <ls_xlikp>-vbeln is empty, this is the Problem.
RaymondGiuseppi
Active Contributor
0 Kudos

You should see a temporary number in the field like $ 1 etc.

How did you define the delivery number range, did you use a FM such as NUMBER_GET_NEXT or do somethin that could reset the number range?

master1980
Explorer
0 Kudos
In My case theres No temporary number, the field is emty and i dont know why.