Welcome to Office Zealot Sign in | Join | Help

Showing Tagged Documents in a DVWP -- Part I

Those who know me, met me, or attended one of my speaking engagements have probably heard me state that SharePoint is "two parts Business to one part Technology".  That's what drew me to it years ago and that's what keeps me going today... SharePoint, more than any other product I know, forces me to think (as both a technologist and a business person).  Here's an example:

You have a document library filled with high value business content and you have been disciplined through the design phase to effectively capture associated metadata.  One of the fields is Authors.  In many instances, you have multiple authors contributing to a single document.  The technologist in you might think to create a multi-select column with all authors included; the tagging process is simply an exercise in checking off checkboxes.  But wait!  There is a business problem.  Often, when multiple people contribute to one document the contribution is not equal.  This is handled by setting the order of authors on the cover page.  Obviously, this gets lost when you have a alpha ordered multi-select column.  After deployment, you are sure to get complaints from all authors whose last name starts with 'Z'!

How to deal with this?  In cases with multiple authors, I like to use multiple columns (Author1, Author2, etc.) then show them in my display (using a Data View Web Part) in the right order.  Something like this:

--  <xsl:value-of select="@Author1" /><br /><xsl:value-of select="@Author2" /><br /><xsl:value-of select="@Author3" />

Another tip, set the <td> tag for your Authors column to include nowrap="nowrap" so you don't get names wrapping onto other lines.

Published Sunday, December 14, 2008 2:23 AM by Mauro
Filed under: , ,

Comments

No Comments
Anonymous comments are disabled