Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Cannot access NodeList in JScript

From: patrick.buxton@------.--.-- (--- ------)
To: NULL
Date: 10/5/2004 8:53:00 AM
Martin Honnen <mahotrash@y...> wrote in message news:<OajxXX7pEHA.3520@T...>...
> Pat Buxton wrote:
> 
> > I'm attempting to convert some old xsl documents so I can use the
> > XSLTransform object in .NET and have been replacing the old xsl:eval
> > tag with xsl:value-of. I can't seem to access the mode passed though
> > if I use "." or current(). The old xsl:eval used to pass "this". Can
> > anyone help please??
> 
> The documentation lists the .NET types arguments passed from XSLT to 
> script have:
> http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfSystemXmlXslXslTransformClassTopic.asp
> 
> An XSLT/XPath node set passed to a script function has the type
>    System.Xml.XPath.XPathNodeIterator
> so there is no NodeList available but instead a subclass of that 
> abstract class XPathNodeIterator and you need to use the properties 
> (like Current) and methods (like MoveNext()) of that class.

I have done this and it now works great as long as I use the
XSLTransform object in .NET to transform the xml. If I enter the
stylesheet processing instruction into the xml, pointing at the
stylesheet, when I open the xml in IE 6, it gives me a scripting
error, assigning null

eg.
function DoSomething(xpNodeIt) {
  var xpNav=xpNodeIt.Current; // works fine in Transform, assigns null
in Browser
  return "";
}

Am I missing something obvious


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent