You need to set the output method to "text", either from the stylesheet itself (xsl:output), or from the command line (!method=text), or from the C# API.

If you are using the API, you need to set the XmlDestination argument of the XsltTransformer.Run method to a Serializer.

Without seeing more specifically what you are doing or what errors you are getting, it's hard to know where you are going wrong, but the fact that you mention XmlWriter suggests you are trying to direct the output to software that's designed to output XML rather than text.

Michael Kay
Saxonica

On 23/02/2012 03:51, Mark Rubelmann wrote:
Hi all,

I'm completely new to Saxon and xslt so please forgive me if this has been answered a million times already.  I'm using Saxon in C# and I'm trying to generate some simple plain text output with xslt.  Despite my best efforts, I haven't been able to make it write anything other than well-formed XML.  Putting in raw text without a root node just throws an exception.  I've tried setting the conformance of my XmlWriter to fragment instead of document but that gave me a different error.  I don't have any of my source code in front of me at the moment and I also don't remember the exact errors, but I just wanted to see if anyone has worked through the same issue.  I can send code snippets tomorrow if it's helpful.

Thanks,
Mark


------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/


_______________________________________________
saxon-help mailing list archived at http://saxon.markmail.org/
saxon-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/saxon-help