Skip to Content
avatar image
Former Member

Exporting a IDOC to text file

Hi All,

I have a IDOC number and also know IDOC type.

I want to export this IDOC to a standard IDOC file to be sent to another system.

How do I do this? Is there some function module available?

Could you provide any sample code?

Thanks a lot.

-Shreyas

(Helpful replies will be rewarded. 😊)

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • avatar image
    Former Member
    May 07, 2006 at 11:50 AM
    Add comment
    10|10000 characters needed characters exceeded

  • May 07, 2006 at 11:55 AM

    Hi,

    Check out the following function modules :

    IDOCS_OUTPUT_TO_FILE

    IDOCS_OUTPUT_TO_INTERNET

    IDOCS_OUTPUT_TO_OWN_FUNCTION

    IDOCS_OUTPUT_TO_R2

    IDOCS_OUTPUT_TO_R3

    Please reward points if it helps.

    Regards,

    Amit Mishra

    Add comment
    10|10000 characters needed characters exceeded

  • May 07, 2006 at 01:49 PM

    Hi Shreyas,

    Welcome to SDN.

    Have you looked <b>File Port</b> (WE21) to ouput IDoc(s) to flat file?

    For more information, please check this link.

    http://help.sap.com/saphelp_di471/helpdata/EN/dc/6b7fa443d711d1893e0000e8323c4f/content.htm

    Regards,

    Ferry Lianto

    Please reward points if helpful as way to say thanks.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    May 08, 2006 at 04:03 AM

    Go to a server and find yourself an idoc that you want to use as a template.

    Display the idoc using WE19.

    Click Inbound file

    Type in a file name - for example /tmp/test (you need to use an AL11 directory).

    Make sure the option 'Start inbound idoc processing of the file immediately' is unchecked.

    Choose overwrite file

    Then click the tick.

    This will write you an idoc into the AL11 directory structure in the system you are operating in.

    Using the download and upload functions (CG3Z & CG3Y), get the file transferred to the production AL11 directories.

    Use WE19 to process your downloaded idoc.

    Use the option 'File as template' to pick up your file.

    You should now be able to process your idoc as you wish

    regards

    Aveek

    Add comment
    10|10000 characters needed characters exceeded