R
Rasheed
Hi ,
Requirement is, I have to load my Xslt file into Exe/DLL.
I have created one .Xslt file and C# code for the same to produce
on .Xml file, like this:
System.Xml.XPath.XPathDocument Xmlpath = new
System.Xml.XPath.XPathDocument(filename);
XslTransform xsl = new XslTransform();
Stream xmlStream = this.GetType().Assembly.GetManifestResourceStream
("SolutionNameSpaceName.FormatConvertion.xslt");
System.Xml.XmlReader xmlReader = new System.Xml.XmlTextReader(xmlStrea
m );
xsl.Load(xmlReader);
XmlTextWriter textWriter = new XmlTextWriter(OutputPath +
"OutputFile.xml ", UTF8Encoding .Defaul t);
xsl.Transform(Xmlpath, list, textWriter);
My problem is with this statement:
Stream xmlStream = this.GetType().Assembly.GetManifestResourceStream
("SolutionNameSpaceName.FormatConvertion.xslt");
I have given my Application nameSpace "." Xslt filename but it returns
null into xmlStream.
For more informaton: I have read some information regarding
http://www.aisto.com/roeder/dotnet/ assembly Reflector, but still I
am unable to do this.
By using Reflector I am unable to see the Xslt file information after
loading the my solution DLL.
thanks in advance
regards
Rs
Requirement is, I have to load my Xslt file into Exe/DLL.
I have created one .Xslt file and C# code for the same to produce
on .Xml file, like this:
System.Xml.XPath.XPathDocument Xmlpath = new
System.Xml.XPath.XPathDocument(filename);
XslTransform xsl = new XslTransform();
Stream xmlStream = this.GetType().Assembly.GetManifestResourceStream
("SolutionNameSpaceName.FormatConvertion.xslt");
System.Xml.XmlReader xmlReader = new System.Xml.XmlTextReader(xmlStrea
m );
xsl.Load(xmlReader);
XmlTextWriter textWriter = new XmlTextWriter(OutputPath +
"OutputFile.xml ", UTF8Encoding .Defaul t);
xsl.Transform(Xmlpath, list, textWriter);
My problem is with this statement:
Stream xmlStream = this.GetType().Assembly.GetManifestResourceStream
("SolutionNameSpaceName.FormatConvertion.xslt");
I have given my Application nameSpace "." Xslt filename but it returns
null into xmlStream.
For more informaton: I have read some information regarding
http://www.aisto.com/roeder/dotnet/ assembly Reflector, but still I
am unable to do this.
By using Reflector I am unable to see the Xslt file information after
loading the my solution DLL.
thanks in advance
regards
Rs