[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Re: node-set

Subject: Re: Re: node-set
From: Dimitre Novatchev <dnovatchev@xxxxxxxxx>
Date: Thu, 5 Jul 2001 04:52:52 -0700 (PDT)
 Re: Re: node-set
Francis Norton wrote:

> 
> Michael Kay wrote:
> > 
> > > Simulating dynamic evaluation of XPath Expressions "by
> > > calling selectNodes() within
> > > a JScript extension" is not always possible.
> > >
> ...
> > Microsoft's selectNodes() function is very inadequately documented, but I
> > think you are almost certainly right.
> > 
> And, at the risk of stating the obvious, selectNodes does return
> nodesets, so you can't use if for any XPath expression which returns a
> number, string or boolean. 
> 
> I hope that when an XPath query function does get included in the DOM
> (is it in DOM 3?) they get this right, it's a frustrating limitation.

This can be done with JScript + MSXML3 (as is currently implemented in the XPath
Visualiser).

One can catch the exception thrown by selectNodes() and check the error message text
(unfortunately the same error number is used by MS for several different errors).

Then, in case this is the text for "our" error message, in a special stylesheet
change a parameter's "select" attribute to our XPath expression and apply the
stylesheet. 

The only thing this stylesheet does is to copy the (scalar) value of the parameter
to the output.

Cheers,
Dimitre Novatchev.

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.