Subject: Re: Accessing the document.XSLDocument From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx> Date: Thu, 9 Nov 2000 10:03:26 +0000 |
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
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Accessing the document.XSLDocument, Bharat . Chintapally | Thread | Identifying empty elements, Sridhar_Ramachandran |
Re: Can I access elements in the ou, Peter Paulus | Date | Re: calling vb functions in xsl, Jeni Tennison |
Month |