Altova User Forum


Important: this is not a Support Forum! Experienced users might answer from time to time questions posted here.
If you need a professional and reliable answer, or if you want to report a bug, please contact Altova Support instead.

Generated an XSLT, but .Net giving me error: Expected token ')', found ','. Options · View
Mastro
Posted: Wednesday, September 17, 2008 3:34:34 PM
Rank: Newbie

Joined: 9/17/2008
Posts: 3
Location: Tampa, FL
I generated a XSLT-RTF file based off a small testing design.
In preview window for HTML and RTF it looks fine...

But when I combine the same XML file with this XSLT file.. I get an error in the XSLT and not sure what I need to change, or if anyone else has had this problem.

and it only happens if I use the one generated from StyleVision.

Exception Details: System.Xml.Xsl.XslTransformException:
Expected token ')', found ','.


Any thoughts?

Edit:

This is my .net code of how I combine the two..
It errors on the Error Line:



Code:
   Dim xmlDoc As XmlDocument
        Dim xslTran As XslCompiledTransform
        Dim root As XmlElement
        Dim nav As XPathNavigator
        Dim writer As XmlTextWriter


            xmlDoc = SPLDoc

            'Load the XSLT for Transformation
            xslTran = New XslCompiledTransform()
            xslTran.Load("C:\XMLToPLRDoc.xslt")


            'Determine the Root object in the XML
            root = xmlDoc.DocumentElement

            'Create the XPath Navigator to navigate throuth the XML
            nav = root.CreateNavigator()

             'Create the RTF by Transforming the XML and XSLT
             writer = New XmlTextWriter("C:\SPL.rtf", System.Text.Encoding.Default)
ERROR LINE: xslTran.Transform(nav, writer)
             writer.close

Mastro
Posted: Wednesday, September 17, 2008 5:17:59 PM
Rank: Newbie

Joined: 9/17/2008
Posts: 3
Location: Tampa, FL
Ok I started a brand new SPS document and left it empty, and genereated XSLT file and I still get the error.
rip
Posted: Thursday, September 18, 2008 7:49:44 AM
Rank: Advanced Member

Joined: 7/17/2008
Posts: 185
Location: Minutiae, Triviality
XSLT out of StyleVision is XSLT 2:

<xsl:stylesheet version="2.0"


System.Xml.XslTransform is XSLT 1:

...System.Xml.Xsl.XslTransform supports the XSLT 1.0 syntax...

(from http://www.xml.com/pub/a/2002/08/14/dotnetxslt.html)

r
mvuong
Posted: Tuesday, October 07, 2008 5:00:52 PM
Rank: Newbie

Joined: 10/7/2008
Posts: 1
I generated a XSLT-RTF file using XSLT 1 and got the same error. As the mater fact only the xslt-html works for me in the .NET application with both XSLT 1 and 2. Anything else gives me the same error. I install the SAXON software which suports the XSLT 2 but still get the same error. Any help is greatly appreciated.
Thank you.
Users browsing this topic
guest

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Use of the Altova User Forum(s) is governed by the Altova User Forums Terms of Service.

Please note that the Altova User Forum was launched so that our users have the possibility to interact and exchange their experiences regarding Altova's product line with one another. It must be pointed out that our support engineers and software engineers regularly post answers to questions in the user forum as an extra service, however this is not a replacement for the regular support mechanism and we cannot in anyway guarantee that a question will be answered or give a specific timeframe for an answer.The user forum was not intended to replace the online support form, but was implemented as an additional source of information after repeated requests for a user based forum in which users can help one another.