[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Assigning values to variables

Subject: RE: Assigning values to variables
From: "Haque, Suraiya" <Suraiya.Haque@xxxxxxx>
Date: Mon, 20 Aug 2001 10:15:24 -0400
xslt assign value to variable
Sorry, I had deleted the line where I was trying to do the assignment.

<xsl:variable name="LastDate">None</xsl:variable>
<xsl:template name="DoTitle">
    <xsl:param name="Date">N/A</xsl:param>
    <xsl:param name="Time">N/A</xsl:param>

    <xsl:variable name="CurrentDate" select="concat($Date,$Time)"/>
	<xsl:if test="$LastDate = 'None'">
    <td>First<xsl:value-of select="$LastDate"/>/<xsl:value-of
select="$CurrentDate"/></td>
    </xsl:if>
	<xsl:if test="$CurrentDate = $LastDate">
    <td><xsl:value-of select="$Date"/>:<xsl:value-of select="$Time"/></td>
    </xsl:if>
	<xsl:if test="$CurrentDate != $LastDate">
-->	<xsl:variable name="LastDate"><xsl:value-of
select="$CurrentDate"/></xsl:variable>
    <td></td>
    </xsl:if>
</xsl:template>

-----Original Message-----
From: Goetz Bock [mailto:bock@xxxxxxxxxxx]
Sent: Monday, August 20, 2001 9:54 AM
To: 'xsl-list@xxxxxxxxxxxxxxxxxxxxxx'
Subject: Re:  Assigning values to variables



On Mon, Aug 20 '01 at 09:32, Haque, Suraiya wrote:
> How do you assign values to a variable once they've already been declared?
You can not assigne a value to a variable that has already been
declared. (In XSLT variables are static)

> [ ... ]
I did not get what your XSLT is supposed to do (or better where in your
XSLT youre (re)assigning a variable's value.
-- 
Goetz Bock                                              IT Consultant
Dipl.-Inf. Univ.

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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.