2023 Feb 20 7:15 AM
Hi All,
I am trying to use method IF_EX_ME_PROCESS_PO_CUST~PROCESS_ITEM to remove incorrect line items from Purchase Order at the time of creation through ME59N.
Using below code I am able to get all the line items. Now after checking some validations, I dont want to add second line item to Purchase Order. How can I remove only that line item?
CALL METHOD im_item->get_data
RECEIVING
re_data = lt_data1.
Regards,
2023 Feb 20 9:53 AM
Did you try to set LOEKZ with method SET_DATA.
(Usually I raise an error in PROCESS_ITEM or CHECK method and invalidate wrong item with method INVALIDATE)
2023 Feb 20 10:52 AM
2023 Feb 22 4:07 AM
Hello Ganesh,
You can set LOEKZ field as mentioned by Raymond.
Here are the possible values for LOEKZ:
EKPO-LOEKZ = 'L' Deleted.
EKPO-LOEKZ = 'S' Blocked