xsl-list
[Top] [All Lists]

Re: [xsl] Filtering new tags

2008-01-25 04:07:57


--------------------------------------------------
From: "Mukul Gandhi" <gandhi(_dot_)mukul(_at_)gmail(_dot_)com>
Sent: Friday, January 25, 2008 10:47 AM
To: <xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com>
Subject: Re: [xsl] Filtering new tags

I am not sure, that your C# program is using MSXML. It seems to be
using .NET classes.

If your stylesheet is not producing the output I suggested, it could
be a bug with the implementation.

I suggest, you can discuss this problem in Microsoft XSL forum. Or,
perhaps, somebody else on this list could help you.


On 1/25/08, buddhi <buddhi(_at_)exceltech-lanka(_dot_)com> wrote:
Yea that is exactly what I need but it is not working for me...

This is the way that I have used it...

XslTransform myXslTransform;
XPathDocument myXPathDocument = new XPathDocument ("C:\New.xml");
myXslTransform = new XslTransform();
myXslTransform.Load( sApplicationPath + @"\style.xsl" );


XmlTextWriter writer = new XmlTextWriter(sApplicationPath +
@"\NewTags.xml", System.Text.Encoding.UTF8);
writer.Formatting = Formatting.Indented;
myXslTransform.Transform(myXPathDocument,null, writer, null);
writer.Flush();
writer.Close();

Above is using C# with msxml

- Buddhi -


--
Regards,
Mukul Gandhi

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--


Sorry, my fault.
You also need to pass a new XmlUrlResolver to the transform method as you are using the document function. myXslTransform.Transform(myXPathDocument, null, writer, new XmlUrlResolver());

Joe
http://joe.fawcett.name

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--