8

How do you set "Allow management of content types?" to "Yes" within a Content Type or List Definition?

7

This can be done either by setting EnableContentType=true in the list definition or in the feature activation event we can set the attribute. Please refer the below links. They will definitely help you in solving your problem.

Enable managing content types by default at list creation

Creating SharePoint 2010 List Definitions in Visual Studio 2010

A Quicker Way to Create Custom SharePoint List Templates

| improve this answer | |
  • Great help! Tank you! Best regards, Tim – Tim Aug 25 '11 at 7:43
6

This says to "toggle the SPList ContentTypesEnabled property from False to True".

Just toggle the SPList ContentTypesEnabled property from False to True. That enables the use of multiple content types on the list.

| improve this answer | |
2

EnableContentTypes="TRUE" instead of EnableContentType="TRUE" (note the s)

| improve this answer | |
1

Go to Library Settings>Advanced settings, then set Allow management of content types? to yes.

| improve this answer | |
  • Would you please brief out your answer. One liner sometimes do not help future visitors. – Asad Refai Oct 5 '15 at 5:28
0

The way I do it is I set the ListCreationInfo and then create the list and enable ContentTypes:

ListCreationInformation creationInfo = new ListCreationInformation(); creationInfo.Title = ListManager.ListTitle; creationInfo.TemplateType = (int)ListtemplateType.Annoucements;

List list = web.Lists.Add(creationInfo); list.Description = ListManager.ListDescription; list.ContentTypesEnabled = true;

| improve this answer | |
0

This is an old thread but may benefit from the PnP Powershell commands available now:

#Config Variables
$SiteURL = "https://<tenantName>.sharepoint.com"
$ListName = "<ListName>"

#Connect to PNP Online
Connect-PnPOnline -Url $SiteURL -Credentials (Get-Credential)

#Enable Content Type
Set-PnPList -Identity $ListName -EnableContentTypes $True

Gleaned from https://www.sharepointdiary.com/2016/01/sharepoint-online-enable-content-types-using-powershell.html

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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