on 08-01-2008 9:55 AM
Hi SDN.
there is a standard bapi BAPI_PO_GETITEMSREL.
I created an RFC ZBAPI_PO_GETITEMSREL.... But i want 2 know whether the RFC i created is said to be a BAPI Wrapper or not ???
because actually i'm in need of BAPI Wrapper.
here is the code ....
FUNCTION ZBAPI_PO_GETITEMREL.
*"----
""Local Interface:
*" IMPORTING
*" VALUE(I_REL_GROUP) LIKE BAPIMMPARA-REL_GROUP OPTIONAL
*" VALUE(I_REL_CODE) LIKE BAPIMMPARA-REL_CODE OPTIONAL
*" VALUE(I_ITEMS_FOR_RELEASE) LIKE BAPIMMPARA-SELECTION DEFAULT
*" 'X'
*" TABLES
*" ET_PO_HEADERS STRUCTURE BAPIEKKOL
*" ET_PO_ITEMS STRUCTURE BAPIEKPOC
*" RETURN STRUCTURE BAPIRETURN OPTIONAL
*"----
if I_ITEMS_FOR_RELEASE is initial.
CALL FUNCTION 'BAPI_PO_GETITEMSREL'
EXPORTING
REL_GROUP = I_REL_GROUP
REL_CODE = I_REL_CODE
ITEMS_FOR_RELEASE = ' '
TABLES
po_headers = ET_PO_HEADERS
po_items = ET_PO_ITEMS
RETURN = RETURN .
else.
CALL FUNCTION 'BAPI_PO_GETITEMSREL'
EXPORTING
REL_GROUP = I_REL_GROUP
REL_CODE = I_REL_CODE
ITEMS_FOR_RELEASE = 'X'
TABLES
po_headers = ET_PO_HEADERS
po_items = ET_PO_ITEMS
RETURN = RETURN .
ENDIF.
ENDFUNCTION.
Hi,
to use it with MI you need to have:
GETLIST
and
GETDETAIL
warpper. Check the documentation in MDK to have a better understanding of the complete process. There is a good example for this and you can take the code from there and change it to your needs.
The single code you send will not help you any further cause it is missing the clear structure between GETLIST and GETDETAIL - that is standard MI behaviour and necessary for correct results. Without this you even can not create any SyncBO in MEREP_SBUILDER.
Hope this helps to bring you any further.
Regards,
Oliver
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
78 | |
9 | |
9 | |
7 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.