Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

screen exit in ME51n

hi all,

my requirement is like this:-

while creating a purchase requisition user want to see the data of last 2 purchase order of the material (last 2 purchase order price and their date).

I have implemented enhancement MEREQ001, and written code in function module EXIT_SAPLMEREQ_001.

There I have been able to display the data of last 2 purchase orders, but I am not being able to save these data in EBAN, where I have created fields in .include structure CI_EBANDB.

My problem is I am not being able to save the data of last 2 purchase orders in these fields of EBAN.

I have searched for solutions in SDN but could'nt find a proper solution.

It will be very helpfull if you people give me a solution to save the data in EBAN.

Thanks in advance.

Former Member
Former Member replied

Hi,

Implement this code in EXIT_SAPLMEREQ_003 exit.

DATA: lv_req_item TYPE mereq_item. 
DATA: re_aktvt TYPE aktvt. 

CALL METHOD im_req_item->get_data 
RECEIVING re_data = lv_req_item.
  
CALL METHOD im_req_item->get_activity 
RECEIVING re_aktvt = re_aktvt.

CASE re_aktvt. 
* Display mode 
WHEN 'A'. 
* Change mode 
WHEN 'V'. 
 lv_req_item-zz_budget = eban-zz_budget.           "<---- Your Feilds here
 lv_req_item-zz_budgetflag = eban-zz_budgetflag.   "<---- Your Feild here
 CALL METHOD im_req_item->set_data 
 EXPORTING im_data = lv_req_item. 
 ex_changed = 'X'. 
ENDCASE.

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question