2013 Sep 27 7:38 AM
Hello
I want to convert xml file to html with using xslt file.
in c# I can do easily with below code.
How can i do in abap.
var xslt = new XslCompiledTransform();
xslt.Load(@"C:\2013000000007.xslt");
xslt.Transform(@"C:\2013000000007.xml", @"output.html");
Thank you.
best regards.
2013 Sep 27 9:09 AM
Hello Osman,
you can do this with the CALL TRANSFORMATION command.
Example:
DATA:
l_xml TYPE string,
l_html TYPE string.
l_xml = get_xml( ).
CALL TRANSFORMATION zxml2html
SOURCE XML l_xml
RESULT XML l_html.
Even if there is a XML output, you can specify, that the XSL-processor will do a HTML-output.
Create your XSL-Transformation with the transaction XSLT_TOOL.
You will have to respect some SAP specials, but I would try to import your existing XSLT and try to activate.
Kind regards,
Hendrik