|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: last() or preceding node if last() have empty text
<xsl:if test="//DARBEDINGUNG[last()]/DARBEDINGUNG.laufzeitbis != '' ">
<xsl:value-of
select="//DARBEDINGUNG[last()]/DARBEDINGUNG.laufzeitbis"/>
</xsl:if>
I would change your xsl:if to an xsl:choose, like this:
<xsl:choose>
<xsl:when test="//DARBEDINGUNG[last()]/DARBEDINGUNG.laufzeitbis != ''
">
<xsl:value-of
select="//DARBEDINGUNG[last()]/DARBEDINGUNG.laufzeitbis"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of
select="//DARBEDINGUNG[last()-1]/DARBEDINGUNG.laufzeitbis"/>
</xsl:otherwise>
</xsl:choose>
cheers
andrew
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.350 / Virus Database: 196 - Release Date: 17/04/2002
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








