[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Accessing the document.XSLDocument
Bharat, > The MSXML doc says the following, but I am getting error that > document.XSLDocument is undefined when I try to access it. > The document.XSLDocument property returns the root node of the XSLT > style sheet document. > > XSLStylesheet = new ActiveXObject('Msxml2.XSLTemplate'); > > XSLStylesheet.stylesheet = document.XSLDocument; // Failing > here Actually I steered you wrong here. I remember having the same problem when I was writing my selectParameters utility and being very confused about it. I assumed that you'd managed to get it to work somehow as you were using document.XSLDocument in your original script. As I recall the problem had to do with the fact that in the second transformation, the document is actually just some text (the output of the previous transformation) rather than being aware that it originates from a transformation, so for the new document, there is no XSLDocument. At least that was my interpretation. Anyway, the only way around it that I could find was to actually generate the stylesheet DOM afresh and set it to that. This involves identifying the file for the stylesheet, which shouldn't be a problem in your case because presumably it's static. Something like: XSLTDOM = new ActiveXObject('Msxml2.FreeThreadedDOMDocument'); XSLTDOM.async = false; XSLTDOM.load('stylesheet.xsl'); ... XSLStylesheet.stylesheet = XSLTDOM; I hope that helps, Jeni --- Jeni Tennison http://www.jenitennison.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|