Test for Null in XSLT Data View
If you insert a data view webpart and then style the td cells for borders, it will not style the empty cells. Very annoying. One way to fix this is to use the xsl:choose tag to do an if/otherwise test for null.
<xsl:choose>
<xsl:when test="categoryName !=null">
<xsl:value-of select="categoryName " />
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="other" />
</xsl:otherwise>
</xsl:choose>
Comments
Post a Comment