One way to solve this problem is to use an XmlTextWriter
in a respective overload of XslCompiledTransform.Transform()
This instnce of XmlTextWriter
must have its Settings
property set with an instance of XmlWriterSettings
for which you have specified whatever newline characters you want as the value of the XmlWriterSettings.NewLineChars
property.
See: http://msdn.microsoft.com/en-us/library/system.xml.xmlwriter.settings.aspx
and
http://msdn.microsoft.com/en-us/library/system.xml.xmlwritersettings.newlinechars.aspx