|
next
|
 Subject: XSL Params inside When Test Author: Sharry Stowell Date: 20 Apr 2006 04:08 PM
|
Just wanna say, great program 'Stylus Studio' guys. Keep up the good work. :)
Hi, i have the following when statement, inside the test I'm tring to use '$rowNo' parameter inside the string, because I'm using a recursive loop. Everything else works great but I want to be able to join, 1, 2 & 3 together.
1) <xsl:when test="contains(substring(//helper/row/row
2) $rowNo
3) /text(), $helperNo,2), '--')">
<xsl:when test="contains(substring(//helper/row/row$rowNo/text(), $helperNo,2), '--')">
I've tried concat (dont work, comes up with NaN2 in the output):
<xsl:when test="contains(concat(substring(//helper/row/row,$rowNo,/text(), $helperNo,2)), '--')">
-----------------------------------------
Input:
//helper/row
<row num="1">
<row1>01020304--0506070809--10111213</row1>
<row2>14--------15----------16------</row2>
<row3>17------18------------19------</row3>
<row4>20------21--------2223--------</row4>
<row5>------24--------25------------</row5>
</row>
------------------
Any help much much appreicated.
Tried the following too:
<xsl:variable name="starter" select="'substring(//helper/row/row'" />
<xsl:variable name="finisher" select="'/text()'" />
<xsl:variable name="finisher2" select="',$helperNo,2)'" />
...
<xsl:value-of select="$starter+$rowNo+$finisher+$finisher2"/>
...
Doesn't work either! :(
PLEASE PLEASE PLEASE - Just want to know if this is possible really (and how if available).
Thank you.
|
|
|
|