SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have developed a custom field type which will show the link to the "workflow history list" in the list (It's a column in the list).

It works fine in sharepoint 2007 site. when i migrate the code to sharepoint 2010, everything works fine but in list view the link is appearing as text with all HTML formatting.

In Display form it works fine. But in list view it displays all the href values, when I put CAMLRendering true in my xml file. how I can overcome it. i read that i need to create a .xsl file for it as the render pattern is obsolete and it will not work for list views.

any help is appreciated.

share|improve this question
up vote 3 down vote accepted

The RenderPattern is obsolete starting from version 14 (SharePoint 2010). So, RenderPattern does not affect how Field is rendered in List View.

In order to define Custom Rendering for a Custom Field, please see How to: Customize the Rendering of a Field on a List View

Brief description.

  1. Create XSLT style sheet for rendering a custom field type. In your case XSLT style sheet would look like shown below:

    <xsl:stylesheet xmlns:x=""
                    version="1.0" exclude-result-prefixes="xsl msxsl ddwrt"
      <xsl:template match ="FieldRef[@Name='YourCustomFieldInternalName']" mode="URL_body">
        <xsl:param name="thisNode" select="."/>
        <!-- Hyperlink for History List goes here --> 

    Note: a)you have to specify match attribute, so that the template matches only fields with the exact internal name of your custom field match="FieldRef[@Name='YourCustomFieldInternalName']" Also instead of Field Internal Name you could specify match attribute for Field ID, like this match="FieldRef[@ID='5a14d1ab-1513-48c7-97b3-657a5ba6c742']"

    b)you have to specify correct mode. It value depends on the Field type, use the following mapping info as guidance: SPFieldComputed (Computed_body), SPFieldUser(User_body), SPFieldText(Text_body) and etc.

  2. Save your XSLT stylesheet, I recommend to use the following naming convention:


  3. Deploy it to %ProgramFiles%\Common Files\Microsoft Shared\web server extensions\14\TEMPLATE\LAYOUTS\XSL

share|improve this answer
I didn't find any information about 1.b) elsewhere so this was pretty helpful, however I needed to change @Name to @FieldType to work in my case. Maybe someone will find it helpful. – Mariusz Ignatowicz Aug 3 '14 at 8:56

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.