2009 May 20 11:22 AM
Hi
While implementing exit MEREQ001. in Exit_SAPLMEREQ_003, I have written:
if not IM_REQ_ITEM is initial.
l_mereq_item = IM_REQ_ITEM->get_data( ).
endif.
I am not getting any line item data. When I debugged, this method is in include - LMEREQF10, where there is a line:
READ TABLE my_data_input_buffer INTO ls_buffer WITH KEY req = me.
At the time of debugging I see that there is no data in table (my_data_input_buffer) and req is empty......
Can anyone give some Idea???
how will req get 'me' and rest of the data??
Thanks in advance.
Hi
While implementing exit MEREQ001. in Exit_SAPLMEREQ_003, I have written:
if not IM_REQ_ITEM is initial.
l_mereq_item = IM_REQ_ITEM->get_data( ).
endif.
I am not getting any line item data. When I debugged, this method is in include - LMEREQF10, where there is a line:
READ TABLE my_data_input_buffer INTO ls_buffer WITH KEY req = me.
At the time of debugging I see that there is no data in table (my_data_input_buffer) and req is empty......
Can anyone give some Idea???
how will req get 'me' and rest of the data??
Thanks in advance.
2009 May 20 11:31 AM
Hi,
May i know your complete requirement..
Thanks,
Shailaja Ainala.
2009 May 21 10:41 AM
Hi
I haven't tried the code yet, but i will try it....
I have a requirement to get a new new tab at item level of PR with around 20 fields on it. I am using the exit MEREQ001. As per me the code in method get_data() should pick up values from log and i should be able to save them.
But as per the code I am supposed to move each and every field.
shouldn't the method get_data() work directly.
Also I have noticed that EXIT_SAPLMEREQ_003 is called after the PAI of customer screen and not while clicking saving data of PR.
What is the best way to move ahead.
I did not use the badi as i am not aware of OO ABAP.
Thanks
2009 May 21 11:40 AM
Hi
Also one more thing, in the include i extended the structure ci_ebandb, but it does not reflect as an include in EBAN???
I cannot include it in EBAN as it is not Z....then it means that I need t create one more structure or what??
Thanks
2009 May 22 7:37 AM
Hi
The include ci_ebandb has extended structure in VSEBAN_CN and not in EBAN table..........though it is a table for PR but not the one used???
What can be done??
Any help???
2009 May 20 6:17 PM
Hi,
Please go thro the following code:
DATA : req_ref TYPE REF TO if_purchase_requisition,
req_items TYPE mmpur_requisition_items,
req_item TYPE mmpur_requisition_item,
req_it_data TYPE mereq_item.
CALL METHOD im_req_item->get_requisition
RECEIVING
re_requisition = req_ref.
IF req_ref IS BOUND.
CALL METHOD req_ref->get_items
RECEIVING
re_items = req_items.
IF req_items IS NOT INITIAL.
LOOP AT req_items INTO req_item.
IF req_item-item IS BOUND.
* Getting the Item Data
CALL METHOD req_item-item->get_data
RECEIVING
re_data = req_it_data.
MOVE eban-zzmaktl TO req_it_data-zzmaktl.
MOVE eban-zzno TO req_it_data-zzno.
MOVE eban-zztext1 TO req_it_data-zztext1.
MOVE eban-zztext2 TO req_it_data-zztext2.
MOVE eban-zztext3 TO req_it_data-zztext3.
MOVE eban-zzrc4 TO req_it_data-zzrc4.
MOVE eban-zzpc5 TO req_it_data-zzpc5.
MOVE eban-zzisep TO req_it_data-zzisep.
MOVE eban-zzdsd TO req_it_data-zzdsd.
MOVE eban-zzres TO req_it_data-zzres.
MOVE eban-zzother TO req_it_data-zzother.
MOVE eban-zzgur_war TO req_it_data-zzgur_war.
MOVE eban-zzpbg TO req_it_data-zzpbg.
MOVE eban-zzinsp TO req_it_data-zzinsp.
MOVE eban-zzqre TO req_it_data-zzqre.
MOVE eban-zzcp_fx TO req_it_data-zzcp_fx.
MOVE eban-zzversion TO req_it_data-zzversion.
* Move all the custom screen fields.
CALL METHOD req_item-item->set_data
EXPORTING
im_data = req_it_data.
ENDIF.
ENDLOOP.
ENDIF.
ENDIF.Regards,
RamaniN