Home
Extended ECM
API, SDK, REST and Web Services
Creation of DOM Documents in Oscript
Francisco_Alcala-Soler_(iaea_001user3_-_(deleted))
Hi,I am reading an XML file into a DOM document and applying an XSL style sheet to it through the XML Oscript package.I have managed to do it this way: DOMDocument xmlDocument // Obtained as parameter XSLProcessor xslProc = XSLProcessor.New() xslProc.SetInput( xmlDocument ) xslProc.SetOutput( "C:\t.xml" ) xslProc.SetStylesheet( "C:\t.xsl" ) xslProc.Transform()but now I would like to be able to build the XSL style sheet on the fly in memory so that I don't have to write it to a file and then apply it.This can be done, since the method "xslProc.SetStylesheet()" could take a DOMDocument or DOMNode as a parameter, instead of the file . However, I am not sure how to build the DOMDocument. I am trying different things with no luck, such as: DOMDocument xslDoc = DOMDocument.New() DOMElement xmlElem = xslDoc.CreateElement("xsl:stylesheet") ... and then play around with AppendChild() Would anybody know how to do this?Thanks a lot, Curro
Find more posts tagged with
Comments
There are no comments yet