Nick Hadlee's Blog on SharePoint and Other Occasional Rants…


The Content Type Is In Use – SharePoint 2010 Error Redux
May 24, 2010, 12:30 pm
Filed under: 2010, Errors, Tips & Tricks

This is a common error if you try to delete a content type in SharePoint. SharePoint is quite rightly trying to stop you from breaking anything by removing a content type if:

  • the content type is being used by a list or library somewhere in your site; or
  • another content type inherits from the content type you are trying to delete

SharePoint provides the SPContentTypeUsages class which allows you to track where the content type is being used and there are some good posts about other things to look for when tracking down the offending content type. In SharePoint 2010 there is an extra place you need to look…the recycle bin.

It seems SharePoint 2010 throws this error if you have assigned the content type to a list or library and it has been deleted to the recycle bin. I’m not sure why, and in this circumstance SPContentTypeUsages is no good to you – it won’t have any references about lists in the recycle bin.

Just remember next time you get this error to check the recycle bin and delete any lists or libraries that reference the content type.

Side Note – SharePoint Manager

A really easy way to get access to the information provided by SPContentTypeUsages is via SharePoint Manager.

SPM 2010

This is what you will see if a list referencing the content type is in the recycle bin…nothing!

Content Type In Use