Mega Code Archive

 
Categories / C# / XML
 

Perform an XSL Transform

using System; using System.Xml; using System.Xml.Serialization; using System.IO; using System.Xml.Xsl; public class TransformXml {     private static void Main() {         XslTransform transform = new XslTransform();                      // Load the XSL stylesheet.         transform.Load("orders.xslt");                      // Transform orders.xml into orders.html using orders.xslt.         transform.Transform("orders.xml", "orders.html", null);     } }