xsl-list
[Top] [All Lists]

Re: Can I use variables in location paths?

2003-05-27 06:37:57



                 What I'd like to do is this (note use of variable)
                

                <xsl:variable name="Scenario">BASECASE</xsl:variable>
                <xsl:variable name="Date">20030408</xsl:variable>

                <xsl:for-each select="PositionFactorLevels/Scenario[
                @Name='${Scenario}' ]/F


The Xpath syntax for a variable reference is $Scenario not ${Scenario}
Also you want the variable reference, not a string starting with a $
so just remove the ' ' and the { }


David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

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



<Prev in Thread] Current Thread [Next in Thread>