Skip to Content
0
Former Member
Aug 09, 2007 at 02:33 PM

Cannot import XML file from local file system

95 Views

Hi all,

I try to import an XML file from a local file system, using the example code from

http://help.sap.com/saphelp_nw04s/helpdata/en/86/8280cf12d511d5991b00508b6b8b11/content.htmhttp://help.sap.com/saphelp_nw04s/helpdata/en/86/8280cf12d511d5991b00508b6b8b11/content.htm">http://help.sap.com/saphelp_nw04s/helpdata/en/86/8280cf12d511d5991b00508b6b8b11/content.htm>

type-pools: ixml.

class cl_ixml definition load.

data: g_ixml type ref to if_ixml.

g_ixml = cl_ixml=>create( ).

data: streamFactory type ref to if_ixml_stream_factory.

streamFactory = g_ixml->create_stream_factory( ).

data: iStream type ref to if_ixml_istream.

iStream = streamFactory->create_istream_uri( "file://c:\public\test.xml" ).

I replaced the last line with

iStream = streamFactory->create_istream_uri( 'file://c:\myXMLfile.xml' ).

After that, iStream is initial.

Is there perhaps sth. wrong with the URI syntax, that I use?

Armin