‎2007 Jan 29 4:26 PM
hi experts i am creating inbound function module for a
custom table processing using IDOCs, can any body help me.
regrads
chandra
‎2007 Jan 29 7:24 PM
hi
jus copy the standard inbound idoc fm and change it according 2 ur need.
Cheers,
Hakim
‎2007 Jan 30 10:12 AM
Hi,
you need to do following steps.
1. create a Fm with following parameters
*" IMPORTING
*" REFERENCE(INPUT_METHOD) LIKE BDWFAP_PAR-INPUTMETHD
*" REFERENCE(MASS_PROCESSING) LIKE BDWFAP_PAR-MASS_PROC
*" EXPORTING
*" VALUE(WORKFLOW_RESULT) LIKE BDWFAP_PAR-RESULT
*" VALUE(APPLICATION_VARIABLE) LIKE BDWFAP_PAR-APPL_VAR
*" VALUE(IN_UPDATE_TASK) LIKE BDWFAP_PAR-UPDATETASK
*" VALUE(CALL_TRANSACTION_DONE) LIKE BDWFAP_PAR-CALLTRANS
*" TABLES
*" IDOC_CONTRL STRUCTURE EDIDC
*" IDOC_DATA STRUCTURE EDIDD
*" IDOC_STATUS STRUCTURE BDIDOCSTAT
*" RETURN_VARIABLES STRUCTURE BDWFRETVAR
*" SERIALIZATION_INFO STRUCTURE BDI_SER
2. Read Idoc Data
READ TABLE idoc_contrl INDEX 1.
v_docnum = idoc_contrl-docnum.
LOOP AT idoc_data WHERE docnum = idoc_contrl-docnum.
CASE idoc_data-segnam.
WHEN <Seg_name>.
MOVE idoc_data-sdata TO <segment>.
WHEN OTHERS.
" no operattions.
ENDCASE.
ENDLOOP.
3. Do the validation of data.
4. process the data according to you needs.
Regards,
Sumit