Groups | Blog | Home
all groups > dotnet xml > may 2006 >

dotnet xml : Use XSLT to add header text to CSV


stephen.surina NO[at]SPAM ferc.gov
5/12/2006 12:39:23 PM
Hello,

I'm trying to convert an xml file to csv using xslt. I can get the
data to write out to the csv. I want to put a line of text at the
beginning of the csv file that describes the content of the file. How
do I do this using xslt?

Thanks!
Peter Flynn
5/13/2006 1:30:02 AM
[quoted text, click to view]

In the template for the document root, add the line you want output,
and then invoke the rest afterwards, eg

<xsl:template match="/">
<xsl:text>AAA,BBB,CCC,DDD,EEE,FFF,...</xsl:text>
<xsl:apply-templates/>
</xsl:template>

///Peter
--
stephen.surina NO[at]SPAM ferc.gov
5/15/2006 4:39:48 AM
Thanks Peter!
AddThis Social Bookmark Button