This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Increment/decrement a variable in XSL


Hi Petr,

> The third and the most straightforward way is to use extension
> functions. However, such a solution would depend on the processor in
> use (to some extent at least).

Do you mean using a node-set() extension function? Yes, you're right -
that would be another way. Create a result tree fragment containing
the correct answers, convert that to a node set using a node-set()
extension function and then count the number of nodes using the
count() function. This is probably less straightforward than counting
the correct answers directly (if that's possible), but more
straightforward than writing a recursive template.

(I hope you weren't suggesting using something like saxon:assign or
writing an extension function that updated a variable... ;)

Cheers,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]