cancel
Showing results for 
Search instead for 
Did you mean: 

Howto transform a Sales Order (idoc) into xml file and download it?

Former Member
0 Kudos

I need to tranform a Sales order into an xml file such that I could download the file onto my disk. I try to transform an IDOC.

I do the following from an example and I get an xml document on screen but I do get get any file downloaded:

*************************************************

DATA: document TYPE REF TO if_ixml_document.

document = g_ixml->create_document( ).

DATA: ostream TYPE REF TO if_ixml_ostream.

ostream = g_stream_factory->create_ostream_uri(

system_id = 'file://C:\test.xml' ).

DATA: renderer TYPE REF TO if_ixml_renderer, rc TYPE i.

renderer = g_ixml->create_renderer( ostream = ostream

document = document ).

rc = renderer->render( ).

document->render( ostream = ostream recursive = ' ').

********************************

Is there something else I should do? Is there another approach for transforming a sales order to an xml file.

The R/3 4.6 system is used.

Thank you

-eglese-

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Eglese,

Another option could be to use XML port configured for the IDOC and use the XML files generated be extracted from Web Dynpro using a file download UI element.

Thanks and Regards,

Sam Mathew

Former Member
0 Kudos

The system does not have WAS6.40 nor WebDynpro.So I have to use something "classical" for R/3 4.6. What could that be?