A
adam bob
Hello,
I found a useful piece of XSL which enables you to create a ticker
based on a list. Currently i can only display the Title. Is there a
way i can display more than one column, i'm sure there is, i need to
display two further columns from my list. this is the current XSL;
<xsl:stylesheet xmlns:x="http://www.w3.org/2001/XMLSchema"
xmlns:d="http://schemas.microsoft.com/sharepoint/dsp" version="1.0"
exclude-result-prefixes="xsl ddwrt msxsl" xmlns:ddwrt="http://
schemas.microsoft.com/WebParts/v2/DataView/runtime" xmlns:xsl="http://
www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-
com:xslt">
<xsl
utput method="html" indent="no"/>
<xsl
aram name="dvt_adhocmode"></xsl
aram>
<xsl
aram name="dvt_adhocfiltermode">xsl</xsl
aram>
<xsl
aram name="dvt_fieldsort"></xsl
aram>
<xsl
aram name="dvt_sortfield"></xsl
aram>
<xsl
aram name="dvt_groupfield"></xsl
aram>
<xsl
aram name="dvt_groupdisplay"></xsl
aram>
<xsl
aram name="dvt_sortdir"></xsl
aram>
<xsl
aram name="dvt_groupdir"></xsl
aram>
<xsl
aram name="dvt_grouptype"></xsl
aram>
<xsl
aram name="dvt_sorttype">text</xsl
aram>
<xsl
aram name="dvt_groupsorttype">text</xsl
aram>
<xsl
aram name="dvt_filterfield"></xsl
aram>
<xsl
aram name="dvt_filterval"></xsl
aram>
<xsl
aram name="dvt_filtertype"></xsl
aram>
<xsl
aram name="dvt_firstrow">1</xsl
aram>
<xsl
aram name="dvt_nextpagedata"></xsl
aram>
<xsl
aram name="dvt_apos">'</xsl
aram>
<xsl
aram name="filterParam"></xsl
aram>
<xsl:template match="/" xmlns:x="http://www.w3.org/2001/
XMLSchema" xmlns:d="http://schemas.microsoft.com/sharepoint/dsp">
<xsl:call-template name="dvt_1"/>
</xsl:template>
<xsl:template name="dvt_1">
<xsl:variable name="StyleName">Table</xsl:variable>
<xsl:variable name="Rows" select="/dsQueryResponse/Rows/
Row"/>
<xsl:variable name="RowCount" select="count($Rows)"/>
<xsl:variable name="IsEmpty" select="$RowCount = 0"/>
<xsl:choose>
<xsl:when test="$IsEmpty">
<xsl:call-template name="dvt_1.empty"/>
</xsl:when>
<xsl
therwise>
<table border="0" width="100%" cellpadding="2"
cellspacing="0" class="ms-nav">
<tr>
</tr>
</table>
</xsl
therwise>
</xsl:choose>
</xsl:template>
<xsl:template name="dvt_1.body">
<xsl
aram name="Rows"/>
<xsl
aram name="FirstRow"/>
<xsl
aram name="LastRow"/>
<xsl:variable name="GroupStyle" select="'auto'"/>
<xsl:for-each select="$Rows">
<img src="_layouts/images/navlink.gif" border="0"/>
<img src="_layouts/images/blank.gif" height="1"
width="10" alt="Icon" border="0"/>
<a style="display:{$GroupStyle}">
<xsl:attribute name="href">Lists/Scrolling%20List/
DispForm.aspx?ID=<xsl:value-of xmlns:xsl="http://www.w3.org/1999/XSL/
Transform" select="@ID"/></xsl:attribute>
<font>
<xsl:attribute name="size"><xsl:value-of
select="@Font_x0020_Size"/></xsl:attribute>
<xsl:attribute name="style">
<xsl:if test="@Bold > 0">font-weight:Bold;</xsl:if>
<xsl:if test="@Italics > 0">font-style:Italic;</xsl:if>
</xsl:attribute>
<xsl:attribute name="color">
<xsl:value-of select="@Color"/>
</xsl:attribute>
<xsl:value-of select="@Title"/>
</font>
</a>
<img src="_layouts/images/blank.gif" height="1"
width="20" alt="Icon" border="0"/>
</xsl:for-each>
</xsl:template>
<xsl:template name="dvt_1.empty">
<xsl:variable name="ViewEmptyText">There are no current
announcements.</xsl:variable>
<table border="0" width="100%">
<tr>
<td class="ms-vb"><xsl:value-of
select="$ViewEmptyText"/></td>
</tr>
</table>
</xsl:template>
</xsl:stylesheet>
Many thanks
Adam
I found a useful piece of XSL which enables you to create a ticker
based on a list. Currently i can only display the Title. Is there a
way i can display more than one column, i'm sure there is, i need to
display two further columns from my list. this is the current XSL;
<xsl:stylesheet xmlns:x="http://www.w3.org/2001/XMLSchema"
xmlns:d="http://schemas.microsoft.com/sharepoint/dsp" version="1.0"
exclude-result-prefixes="xsl ddwrt msxsl" xmlns:ddwrt="http://
schemas.microsoft.com/WebParts/v2/DataView/runtime" xmlns:xsl="http://
www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-
com:xslt">
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl
<xsl:template match="/" xmlns:x="http://www.w3.org/2001/
XMLSchema" xmlns:d="http://schemas.microsoft.com/sharepoint/dsp">
<xsl:call-template name="dvt_1"/>
</xsl:template>
<xsl:template name="dvt_1">
<xsl:variable name="StyleName">Table</xsl:variable>
<xsl:variable name="Rows" select="/dsQueryResponse/Rows/
Row"/>
<xsl:variable name="RowCount" select="count($Rows)"/>
<xsl:variable name="IsEmpty" select="$RowCount = 0"/>
<xsl:choose>
<xsl:when test="$IsEmpty">
<xsl:call-template name="dvt_1.empty"/>
</xsl:when>
<xsl
<table border="0" width="100%" cellpadding="2"
cellspacing="0" class="ms-nav">
<tr>
name="LastRow" select="$RowCount"/></xsl:call-template></marquee></td>said:<xsl:with-param name="FirstRow" select="1"/><xsl:with-param
</tr>
</table>
</xsl
</xsl:choose>
</xsl:template>
<xsl:template name="dvt_1.body">
<xsl
<xsl
<xsl
<xsl:variable name="GroupStyle" select="'auto'"/>
<xsl:for-each select="$Rows">
<img src="_layouts/images/navlink.gif" border="0"/>
<img src="_layouts/images/blank.gif" height="1"
width="10" alt="Icon" border="0"/>
<a style="display:{$GroupStyle}">
<xsl:attribute name="href">Lists/Scrolling%20List/
DispForm.aspx?ID=<xsl:value-of xmlns:xsl="http://www.w3.org/1999/XSL/
Transform" select="@ID"/></xsl:attribute>
<font>
<xsl:attribute name="size"><xsl:value-of
select="@Font_x0020_Size"/></xsl:attribute>
<xsl:attribute name="style">
<xsl:if test="@Bold > 0">font-weight:Bold;</xsl:if>
<xsl:if test="@Italics > 0">font-style:Italic;</xsl:if>
</xsl:attribute>
<xsl:attribute name="color">
<xsl:value-of select="@Color"/>
</xsl:attribute>
<xsl:value-of select="@Title"/>
</font>
</a>
<img src="_layouts/images/blank.gif" height="1"
width="20" alt="Icon" border="0"/>
</xsl:for-each>
</xsl:template>
<xsl:template name="dvt_1.empty">
<xsl:variable name="ViewEmptyText">There are no current
announcements.</xsl:variable>
<table border="0" width="100%">
<tr>
<td class="ms-vb"><xsl:value-of
select="$ViewEmptyText"/></td>
</tr>
</table>
</xsl:template>
</xsl:stylesheet>
Many thanks
Adam