Linked Data Source/Lists

Display data from multiple sources in a single Data View this article also applies in SP2010

Display item counts in a Data View Web Part talks about having two lists and links them. Then displays a count of the sub list items.



Show file attachments for SharePoint list items in a Data View Web Part (DVWP)

I needed to display all the attachments of a SharePoint list item in a DVWP. Thanks to Marc’s article for helping me out.

I added the code that Marc provided between a <td> tag. Magically, it worked!


<xsl:text>Attachments: </xsl:text>
<xsl:element name=”SharePoint:AttachmentsField”>
<xsl:attribute name=”runat”>server</xsl:attribute>
<xsl:attribute name=”FieldName”>Attachments</xsl:attribute>
<xsl:attribute name=”ControlMode”>Display</xsl:attribute>
<xsl:attribute name=”Visible”>true</xsl:attribute>
<xsl:attribute name=”ItemId”>
<xsl:value-of select=”@ID”/>