[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Rajesh Jain wrote:
We need to see the complete code of the stylesheet you use, if the XML parsing error occurs in that stylesheet.
If the code below is your complete stylesheet then you have certainly removed essential elements like the xsl:stylesheet element and of course also the xsl:template.
--
Re: [xsl] Help XSL Transformation of Data
Subject: Re: [xsl] Help XSL Transformation of Data From: Martin Honnen <Martin.Honnen@xxxxxx> Date: Mon, 28 Sep 2009 17:31:56 +0200 |
Rajesh Jain wrote:
I am using the code snippet you provided, along with the row to output the time. But this doesn't seem to work. The only thing I changed was to remove the template definition and added Chart-Data before Root.
I get an error XML Parsing Error: no element found
I am complete newbie, so please let me know if I have to use template definition and how to use it.
We need to see the complete code of the stylesheet you use, if the XML parsing error occurs in that stylesheet.
If the code below is your complete stylesheet then you have certainly removed essential elements like the xsl:stylesheet element and of course also the xsl:template.
<xsl:key name="k1" match="Metrics/*" use="local-name()"/>
<chart_data> <!-- Category (X axis) date row --> <row> <null/>
<xsl:for-each select="Chart-Data/Root/Item[position()=1]/Statistics/Item">
<string><xsl:value-of select="@StartRawDateAndTime"/></string>
</xsl:for-each>
</row>
<xsl:for-each select="Chart-Data/Root/Item/Statistics/Item[1]/Metrics/*">
<row>
<string><xsl:value-of select="local-name()"/></string>
<xsl:for-each select="key('k1', local-name())">
<number><xsl:value-of select="number(@TotalValue)"/></number>
</xsl:for-each>
</row>
</xsl:for-each>
</chart_data>
--
Martin Honnen http://msmvps.com/blogs/martin_honnen/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Help XSL Transformation o, Rajesh Jain | Thread | Re: [xsl] Help XSL Transformation o, Rajesh Jain |
Re: [xsl] Help XSL Transformation o, Rajesh Jain | Date | Re: [xsl] Use of xsl:apply-template, Wendell Piez |
Month |
Keywords