Perform an XSL Transform : XML Transform « XML « C# / C Sharp






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);
    }
}


           
         
    
  








Related examples in the same category

1.Use XslCompiledTransform
2.Read command line input and do the xml xsl translation
3.Illustrates the XslTransform classIllustrates the XslTransform class
4.XML transformation: transform XML file to HTML file
5.Perform an XSL Transformation using XML and XSL content and with some XSLT arguments
6.Xslt Transformation Helper