Hi all,
I was hoping that some of you would be able to help me out a bit here.
I need to shorten down a number, which I get from an XML document (through datalists), to two decimals, insted of four.
Here's my code in XSLT:
<xsl:for-each select="item">
<xsl:if test="Row.ColumnName = 'depositum_total' and Row.Value != '' and Row.Value != '0'">
<xsl:variable name="enhedspris" select="Row.Value" />
<br />Depositum <br />kr. <xsl:value-of select='format-number($enhedspris, "#.00")' />
</xsl:if>
</xsl:for-each>
The result here is NaN.
If replace format-number with just the variable, like this:
<xsl:value-of select='$enhedspris' />
then I get e.g. 10304,5900...
So from what I can tell, the variable is set correctly. The issue is somewhere in the format-number. I've tried just about anything that came to my mind, but nothing has worked really...
I hope that one of you guys are able to give me an answer to this :)
Thanks in advance.