11-22-2007 5:18 PM
Hi,
I have XML file in a string and i need to display it in a text box, how to do it Positioning all tags?
Thanks,
Priscila Pereira.
11-22-2007 5:20 PM
Hi,
Try this way.
data xml type string.
data xml_document type ref to cl_xml_document.
data subrc type sysubrc.
xml = '<?xml version="1.0" encoding="utf-16"?><a>123</a>'.
"Instatiate the cl_xml_document object
create object xml_document.
"Send XML to method parse_string from class cl_xml_document
subrc = xml_document->parse_string( xml ).
"Finally display all XML with Tag using method display that organize Tags itself
xml_document->display( ).
Regards,
Marcelo Ramos
11-22-2007 5:20 PM
Hi,
Try this way.
data xml type string.
data xml_document type ref to cl_xml_document.
data subrc type sysubrc.
xml = '<?xml version="1.0" encoding="utf-16"?><a>123</a>'.
"Instatiate the cl_xml_document object
create object xml_document.
"Send XML to method parse_string from class cl_xml_document
subrc = xml_document->parse_string( xml ).
"Finally display all XML with Tag using method display that organize Tags itself
xml_document->display( ).
Regards,
Marcelo Ramos