Subject: [xsl] problems with position() and following-sibling From: Georges Schmitz <georges.schmitz@xxxxxxxxx> Date: Fri, 12 Aug 2005 10:37:13 +0200 |
I have an Excel Sheet in xml format, that is basically build out of 6 columns. Now and then I have a value in column 7, that should be made a footnote in column 2 of the output. Column 1 is to be eliminated in the output (I just use it for grouping).
<xsl:template match="Row"> <row> <xsl:apply-templates/> </row> </xsl:template>
But this way, I don't get any footnote at all (probably, I'm using position() in an incorrect way?). While playing around with the line
I got the impression that position() and following-sibling::e:Cell[x] do not see the "absolute" node positions of the cells in the original tree, but only the filtered set of the match by
which should result in 5 cells (am I right here?). In consequence, I tried to switch down the node number in the if statement, and with "5" I finally got footnotes (in the first cell)
not really knowing why "5" and not "6" (if the position is calculated from the current context node of the first cell?). Any further attempts to refine the statement with position()=2, to move the footnote to the second column, didn't succeed.
I have to admit, that my proceeding was "try and error" here (very unsatisfying to me), so can someone please point out, what is going on in my template.
Thanks, Georges
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] How can I placed end tags, Michael Kay | Thread | Re: [xsl] problems with position() , Kenneth Stephen |
RE: [xsl] How can I placed end tags, Michael Kay | Date | Re: [xsl] Unique values in tags, António Mota |
Month |