Altova Mailing List Archives>Archive Index >xsl-list Archive Home >Recent entries >Thread Prev - [xsl] Using the Input Document to Control Generation of Numbers in the Output >Thread Next - RE: [xsl] Using the Input Document to Control Generation of Numbers in the Output Re: [xsl] Using the Input Document to Control Generation of Numbers in the OutputTo: Date: 10/2/2007 12:51:00 PM Michael Kay wrote: [...] This is a typical use case for recursion (even in XSLT 2.0). What about <xsl:template match="incoming"> <outgoing name="{@name}" index="{count(preceding-sibling::*[not(@size)]) + 1 + sum(preceding-sibling::*/@size)}"></outgoing> </xsl:template> ? Regards, George --------------------------------------------------------------------- George Cristian Bina - http://aboutxml.blogspot.com/ <oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger www.---.com | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
