WM Function module RFC Used the same way in S/4HANA

L_TO_CANCEL Cancel Transfer Order

Cancels open items of a transfer order, like LT15, either all open items or the items listed in T_LTAP_CANCL. It is used in RF and interface programs when a warehouse task is no longer needed. Confirmed items cannot be cancelled; the function then raises TO_CONFIRMED or ITEM_CONFIRMED.

Function group
L03B
Remote-enabled (RFC)
Yes
Type
Function module

Importing parameters

ParameterTypeDescriptionRequired
I_LGNUMLTAK-LGNUMWarehouse numberYes
I_TANUMLTAK-TANUMTransfer order numberYes
I_SOLEXLTAK-SOLEXPlanned processing time from external system—
I_CANCLRL03B-CANCLCancel all open items—
I_SUBSTRL03T-SUBSTInclude subsystem items—
I_QNAMELTAP-QNAMEUser performing the cancellation—
I_UPDATE_TASKRL03A-VERBUUpdate via update task—
I_COMMIT_WORKRL03B-COMITCommit inside the function—

Tables parameters

ParameterTypeDescriptionRequired
T_LTAP_CANCLLTAP_CANCLItems to cancelYes

Exceptions

  • TO_CONFIRMED — Transfer order already confirmed
  • TO_DOESNT_EXIST — Transfer order does not exist
  • ITEM_CONFIRMED — Item already confirmed
  • ITEM_DOESNT_EXIST — Item does not exist
  • FOREIGN_LOCK — Object locked by another user
  • DOUBLE_LINES — Duplicate lines passed
  • NOTHING_TO_DO — Nothing to process
  • XFELD_WRONG — Invalid indicator value
  • SU_MOVEMENT_PARTLY_CONFIRMED — Storage unit movement partly confirmed
  • UPDATE_WITHOUT_COMMIT — Update task used without commit
  • NO_AUTHORITY — No authorization

Call template (ABAP)

A skeleton generated from the interface. It lists mandatory importing parameters, exporting parameters and tables; declare the variables with suitable types in your own program.

CALL FUNCTION 'L_TO_CANCEL'
  EXPORTING
    i_lgnum = lv_i_lgnum
    i_tanum = lv_i_tanum
  TABLES
    t_ltap_cancl = lt_t_ltap_cancl
  EXCEPTIONS
    to_confirmed = 1
    to_doesnt_exist = 2
    item_confirmed = 3
    item_doesnt_exist = 4
    foreign_lock = 5
    double_lines = 6
    nothing_to_do = 7
    xfeld_wrong = 8
    OTHERS = 9.

Related tables

Can't find the report you need?

We also build anything that is not in the catalog. Describe it briefly and we will suggest the right solution.

Request a custom report