Is it possible to create a table with gridlines like a .NET control, rather than just setting the border to greater than 0?
Here is the XSLT I am trying to do this with :
<?xml version="1.0" encoding="UTF-8" ?>
<xsl:stylesheet version="1.0" xmlns:xsl=" xmlns:asp="Remove">
<xsl:template match="Users">
<html>
<title>XSL Transformation</title>
<body>
<table width="100%" height="0" cellspacing="1" cellpadding="0">
<tr bgcolor="#ff0000">
<td background="images/ListHeaderRed.jpg" width="70px">
<font size="2px" color="#ffffff" family="verdana">
<b>User Key</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="100px">
<font size="2px" color="#ffffff" family="verdana">
<b>Team Manager</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="70px">
<font size="2px" color="#ffffff" family="verdana">
<b>Team Type</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="100px">
<font size="2px" color="#ffffff" family="verdana">
<b>Territory Code</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="70px">
<font size="2px" color="#ffffff" family="verdana">
<b>User Name</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="70px">
<font size="2px" color="#ffffff" family="verdana">
<b>User Login</b>
</font>
</td>
</tr>
<xsl:for-each select="row">
<xsl:choose>
<!--Returns the index position of the node that is currently being processed
Example: //book[position()<=3]
Result: Selects the first three book elements-->
<xsl:when test="position() mod 2 = 0">
<tr bgcolor="#d3d3d3">
<td>
<xsl:value-of select="@UserKey"/>
</td>
<td>
<xsl:value-of select="@TeamManager"/>
</td>
<td>
<xsl:value-of select="@TeamType"/>
</td>
<td>
<xsl:value-of select="@TerritoryCode"/>
</td>
<td>
<xsl:value-of select="@UserName" />
</td>
<td>
<xsl:value-of select="@UserLogin" />
</td>
</tr>
</xsl:when>
<xsltherwise>
<tr bgcolor="#f5f5f5">
<td>
<xsl:value-of select="@UserKey"/>
</td>
<td>
<xsl:value-of select="@TeamManager"/>
</td>
<td>
<xsl:value-of select="@TeamType"/>
</td>
<td>
<xsl:value-of select="@TerritoryCode"/>
</td>
<td>
<xsl:value-of select="@UserName" />
</td>
<td>
<xsl:value-of select="@UserLogin" />
</td>
</tr>
</xsltherwise>
</xsl:choose>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
Here is the XSLT I am trying to do this with :
<?xml version="1.0" encoding="UTF-8" ?>
<xsl:stylesheet version="1.0" xmlns:xsl=" xmlns:asp="Remove">
<xsl:template match="Users">
<html>
<title>XSL Transformation</title>
<body>
<table width="100%" height="0" cellspacing="1" cellpadding="0">
<tr bgcolor="#ff0000">
<td background="images/ListHeaderRed.jpg" width="70px">
<font size="2px" color="#ffffff" family="verdana">
<b>User Key</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="100px">
<font size="2px" color="#ffffff" family="verdana">
<b>Team Manager</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="70px">
<font size="2px" color="#ffffff" family="verdana">
<b>Team Type</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="100px">
<font size="2px" color="#ffffff" family="verdana">
<b>Territory Code</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="70px">
<font size="2px" color="#ffffff" family="verdana">
<b>User Name</b>
</font>
</td>
<td background="images/ListHeaderRed.jpg" width="70px">
<font size="2px" color="#ffffff" family="verdana">
<b>User Login</b>
</font>
</td>
</tr>
<xsl:for-each select="row">
<xsl:choose>
<!--Returns the index position of the node that is currently being processed
Example: //book[position()<=3]
Result: Selects the first three book elements-->
<xsl:when test="position() mod 2 = 0">
<tr bgcolor="#d3d3d3">
<td>
<xsl:value-of select="@UserKey"/>
</td>
<td>
<xsl:value-of select="@TeamManager"/>
</td>
<td>
<xsl:value-of select="@TeamType"/>
</td>
<td>
<xsl:value-of select="@TerritoryCode"/>
</td>
<td>
<xsl:value-of select="@UserName" />
</td>
<td>
<xsl:value-of select="@UserLogin" />
</td>
</tr>
</xsl:when>
<xsltherwise>
<tr bgcolor="#f5f5f5">
<td>
<xsl:value-of select="@UserKey"/>
</td>
<td>
<xsl:value-of select="@TeamManager"/>
</td>
<td>
<xsl:value-of select="@TeamType"/>
</td>
<td>
<xsl:value-of select="@TerritoryCode"/>
</td>
<td>
<xsl:value-of select="@UserName" />
</td>
<td>
<xsl:value-of select="@UserLogin" />
</td>
</tr>
</xsltherwise>
</xsl:choose>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>