|
|
Rank: Newbie
Joined: 2/27/2009 Posts: 76 Location: Paris, France
|
Hello,
When transforming with the generated XSLT file (when transforming with .NET, or Word, or other client but StyleVision), I obtains an error, because a variable was duplicated in the same context:
<xsl:variable name="altova:RowStyle0"> <xsl:text>\trrh0\trhdr</xsl:text> <xsl:variable name="altova:CurrGridPos_0" select="$altova:nTableIndentTw_0"/> <xsl:text>\clvertalc\clbrdrt\brdrs\brdrcf142\brdrw15\clbrdrb\brdrs\brdrcf143\brdrw15\clbrdrl\brdrs\brdrcf142\brdrw15\clbrdrr\brdrs\brdrcf143\brdrw15\clpadl0\clpadfl3\clpadb0\clpadfb3\clpadt0\clpadft3\clpadr0\clpadfr3\cellx</xsl:text> <xsl:variable name="altova:CurrGridPos_0" select="$altova:CurrGridPos_0 + $altova:nColumnWidthTw_0_0"/> <xsl:value-of select="ceiling($altova:CurrGridPos_0)"/> <xsl:text>\clvertalc\clbrdrt\brdrs\brdrcf142\brdrw15\clbrdrb\brdrs\brdrcf143\brdrw15\clbrdrl\brdrs\brdrcf142\brdrw15\clbrdrr\brdrs\brdrcf143\brdrw15\clpadl0\clpadfl3\clpadb0\clpadfb3\clpadt0\clpadft3\clpadr0\clpadfr3\cellx</xsl:text> <xsl:variable name="altova:CurrGridPos_0" select="$altova:CurrGridPos_0 + $altova:nColumnWidthTw_0_1"/> <xsl:value-of select="ceiling($altova:CurrGridPos_0)"/> </xsl:variable>
This "duplication" appears when I try to inset a table(even empty) with multiple columns and rows.
When previewing the file in StyleVision or transforming this file with XmlSpy everything works... I ask myself how is it possible..., probably Altova in its applications does not respect exactly the XSLT rules...
|
|
Rank: Newbie
Joined: 2/27/2009 Posts: 76 Location: Paris, France
|
I tried to change the generated node
<xsl:variable name="altova:RowStyle0"> <xsl:text>\trrh0</xsl:text> <xsl:variable name="altova:CurrGridPos_0" select="$altova:nTableIndentTw_0"/> <xsl:text>\clvertalc\clbrdrt\brdrs\brdrcf142\brdrw15\clbrdrb\brdrs\brdrcf143\brdrw15\clbrdrl\brdrs\brdrcf142\brdrw15\clbrdrr\brdrs\brdrcf143\brdrw15\clpadl30\clpadfl3\clpadb30\clpadfb3\clpadt30\clpadft3\clpadr30\clpadfr3\cellx</xsl:text> <xsl:variable name="altova:CurrGridPos_1" select="$altova:CurrGridPos_0 + $altova:nColumnWidthTw_0_0"/> <xsl:value-of select="ceiling($altova:CurrGridPos_0)"/> <xsl:text>\clvertalc\clbrdrt\brdrs\brdrcf142\brdrw15\clbrdrb\brdrs\brdrcf143\brdrw15\clbrdrl\brdrs\brdrcf142\brdrw15\clbrdrr\brdrs\brdrcf143\brdrw15\clpadl30\clpadfl3\clpadb30\clpadfb3\clpadt30\clpadft3\clpadr30\clpadfr3\cellx</xsl:text> <xsl:variable name="altova:CurrGridPos_2" select="$altova:CurrGridPos_1 + $altova:nColumnWidthTw_0_1"/> <xsl:value-of select="ceiling($altova:CurrGridPos_1)"/> </xsl:variable>
and at least it works, but I am not sure what should really be inside...
It's clear that this is a bug in StyleVision... Even two, if we consider that the transformation should not pass using the generated version of XSLT.
|
|
Rank: Advanced Member
Joined: 12/13/2005 Posts: 2,856 Location: Mauritius
|
Yes, you are right, both bugs should be resolved in the upcoming Service Pack (no due date yet available)
|
|
Rank: Newbie
Joined: 2/27/2009 Posts: 76 Location: Paris, France
|
ok. Thanks.
|
|
Rank: Newbie
Joined: 10/26/2009 Posts: 6 Location: Lebanon, VA
|
This issue still seems to exist as of service pack 1. Is the above service pack referenced sp1, or a subsequent pack that still hasn't been released? This is a pretty huge issue that will influence our license upgrade purchase.
|
|
Rank: Advanced Member
Joined: 12/13/2005 Posts: 2,856 Location: Mauritius
|
This issue has been definitely resolved (as many customers have already confirmed) in the current v2009sp1 release. Please make sure to download the latest installer and use it.
|
|
Rank: Newbie
Joined: 10/26/2009 Posts: 6 Location: Lebanon, VA
|
Is there any reason it would not be resolved in the Enterprise Edition trial version? I produced the actual xslt out of the File > Save Generated Files menu option. Is there anything I could be doing wrong?
|
|
Rank: Advanced Member
Joined: 12/13/2005 Posts: 2,856 Location: Mauritius
|
Trial version is the same. The only thing which might be wrong is that you don't have the latest .exe Uninstall yours, download the newest one from the web and install again - everything should be fine then.
|
|
Rank: Newbie
Joined: 10/28/2002 Posts: 1,283 Location: AT
|
The bug only applies to xslt 1.0. In xslt 2.0 it is possible to declare variables of the same name in the same context (shadowing). If you are using .Net to transform your xml files, you should only use xslt 1.0 stylesheets because .net is not xslt 2.0 compliant.
|
|
Rank: Newbie
Joined: 10/26/2009 Posts: 6 Location: Lebanon, VA
|
Absolutely correct, and I believe I'm correct in saying that this particular thread did not hint at this fact before now. Since .Net was our launching platform, it was of course expecting valid xslt 1.0 code instead of the 2.0 we were generating originally. After switching to 1.0, everything is as it should be.
Thanks so much for everyone's input.
|
|
|
guest |