Question

I need to add some custom properties to a document set. Is there an ootb way to do this or inheriting the content type is the only solution?

Was it helpful?

Solution

It depends on what you see as an ootb solution.

A Document Set is a 'special' content type with ContentType ID="0x0120D520", so sort of a Folder content type. To add custom properties (fields) to a document set you can go several ways:

  • Add a site/list column through the SharePoint UI as you would do with a regular content type
  • Add a SPField in code, e.g. in an event receiver
  • Add a SPField in the Document Set content type definition declaratively

If you can do it for a regular content type, you can do it for a document set, since it's 'just a content type'.

If you want your custom fields to be shared to the document types in the document set or shown on the welcome page, have a look at this Visual How To for a highly detailed definition.

Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top