[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

[xsl] xalan-tomcat: Could not find variable with the name of fg2bg_colo rizer


Subject: [xsl] xalan-tomcat: Could not find variable with the name of fg2bg_colo rizer
From: "Jiang, Peiyun" <Peiyun.Jiang@xxxxxx>
Date: Thu, 13 Jun 2002 13:05:48 -0400

I'm using xerces 2.0.1/xalan 2.3.1 and tomcat 4.0.3. Can anybody tell me
what happened? Thanks.

Peiyun
------------------------------------
** Transformer Factory error
javax.xml.transform.TransformerConfigurationException:
javax.xml.transform.TransformerException:
org.apache.xml.utils.WrappedRuntimeException: Could not find variable with
the name of fg2bg_colorizer
javax.xml.transform.TransformerConfigurationException:
javax.xml.transform.TransformerException:
org.apache.xml.utils.WrappedRuntimeException: Could not find variable with
the name of fg2bg_colorizer at
org.apache.xalan.processor.TransformerFactoryImpl.newTemplates(TransformerFa
ctoryImpl.java:995) at
org.apache.xalan.processor.TransformerFactoryImpl.newTransformer(Transformer
FactoryImpl.java:799) at XSLTServlet.doPost(XSLTServlet.java:101) at
XSLTServlet.doGet(XSLTServlet.java:53) at .....
--------------------------------------



-----Original Message-----
From: Michael Kay [mailto:michael.h.kay@xxxxxxxxxxxx]
Sent: Thursday, June 13, 2002 11:54 AM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: RE: [xsl] Conditional xsl:sort


> I have the following:
> 
> ...
> <xsl:for-each select="Transaction">
>     <xsl:sort select="*[local-name() = string($sortby)]" 
> data-type="{$datatype}" order="{$order}"/>
> 
>     <xsl:if test="$sortby = 'Description'">
>         <xsl:sort select="Code" data-type="number" order="{$order}"/>
>     </xsl:if>
> ...
> 
> and I'm getting this:
> 
> ...
> Keyword xsl:sort may not be used here.
> ...
> 
> for the second, conditional, xsl:sort.  Why?

Because <xsl:sort> may not be used inside <xsl:if>. You're trying to
make the language up as you go along.

Michael Kay
Software AG
home: Michael.H.Kay@xxxxxxxxxxxx
work: Michael.Kay@xxxxxxxxxxxxxx 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



Current Thread