Thanks in advance,
Linda
"L. Smith" <lsm...@utilityguide.com> wrote in message
news:uLXUf#Q2CHA...@TK2MSFTNGP11.phx.gbl...
"Joel Askey" <joel....@shs.com> wrote in message
news:esL5dVU2...@TK2MSFTNGP11.phx.gbl...
You can load an XslTransform with an XPathNaviagator. And you can get
an XPathNaviagtor from an XmlDocument object. If you create a new
XmlDocument object, it has a LoadXml() method that will load raw XML from a
string for you. You can then call CreateNavigator on the XmlDocument to get
the navigator to pass to the XslTransform::Load method.
-Shawn
--
This posting is provided "AS IS" with no warranties, and confers no rights.
Please do not send email directly to this alias, this alias is for newsgroup
purposes only.
"Joel Askey" <joel....@shs.com> wrote in message
news:esL5dVU2...@TK2MSFTNGP11.phx.gbl...
System.Xml.XmlTextReader xmlreader = new
System.Xml.XmlTextReader(Server.MapPath("xmlfile1.xml"));
System.Xml.XPath.XPathDocument xmlSource = new
System.Xml.XPath.XPathDocument(xmlreader);
trans.Transform(xmlSource,null,Response.OutputStream);
reader.Close();
xmlreader.Close();
}
private string getXSLT()
{
System.Text.StringBuilder sb = new System.Text.StringBuilder();
sb.Append("<?xml version='1.0'?><xsl:stylesheet version='1.0' ");
sb.Append("xmlns:xsl='http://www.w3.org/1999/XSL/Transform'>");
sb.Append("<xsl:template match='*'>");
sb.Append("<xsl:copy><xsl:apply-templates select='*'/>");
sb.Append("</xsl:copy></xsl:template></xsl:stylesheet>");
return(sb.ToString());
}
--
Kirk Allen Evans
Author, "XML And ASP.NET", New Riders Publishing
www.xmlandasp.net
http://dotnetweblogs.com/kaevans
"L. Smith" <lsm...@utilityguide.com> wrote in message
news:uLXUf#Q2CHA...@TK2MSFTNGP11.phx.gbl...