question

LoganathanKamalakkannan-6089 avatar image
0 Votes"
LoganathanKamalakkannan-6089 asked CaseyYangMSFT-4714 commented

In Sharepoint 2013, not able to Create Custom Content Type using the Built-in Content Type as Parent (Workflow Task)?

We want create a Custom Content Type in SP2013, who's parent should be workflow task (Content TypeID - 0x010801), but not able to create Custom content Type under Workflow Task?
please suggest how this can be achieved?

Note: the built-in content types (System, Item, Task, Workflow Task) and its Id's can be viewed using PowerShell but not from the URL, please refer the image for reference.

Thanks in Advance!

131994-image.png [2]: /answers/storage/attachments/131994-image.png
131978-image.png
132273-image.png
132257-workflowtask2.jpg


sharepoint-devsharepoint-workflow
image.png (47.8 KiB)
image.png (61.8 KiB)
image.png (18.3 KiB)
workflowtask2.jpg (58.8 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

CaseyYangMSFT-4714 avatar image
0 Votes"
CaseyYangMSFT-4714 answered CaseyYangMSFT-4714 commented

Hi @LoganathanKamalakkannan-6089,

Did you create new custom content type in "site content type"? Per my test, I could create new custom content type using the workflow task content type.

Settings > Site settings > Site content types > create > Select parent content type from "List Content Types" > Parent Content Type "Workflow Task"

132193-1.png

And please check your Workflow Task Content Type feature is activated.

Settings > Site settings > Manage site features > Workflow Task Content Type Active

132194-image.png


If an Answer is helpful, please click "Accept Answer" and upvote it.

Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.



1.png (6.3 KiB)
image.png (9.3 KiB)
· 4
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi CaseyYangMSFT,

Thanks for the answer, but the Workflow Task Content Type Feature is already set to 'Active',
Here the problem is something different, The Workflow Task content Type that exists has no parent link, similarly there is no option to add the content types like Task, Item, System, how to get/view these hierarchy and add to custom content type?

please refer the newly added screen shots for reference in the question section

![132273-image.png][3]
![132257-workflowtask2.jpg][4]

Best Regards,
Kamal

0 Votes 0 ·
CaseyYangMSFT-4714 avatar image CaseyYangMSFT-4714 LoganathanKamalakkannan-6089 ·

Hi @LoganathanKamalakkannan-6089,

You could try to use the following PowerShell commands to create content types:

 Add-PSSnapin Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue
     
 #Set Parameters
 $SiteURL = "https://intranet.crescent.com/"
 $ContentTypeName = "xxx"
     
 #Get the Root web
 $web = Get-SPWeb $SiteURL
     
 #Get parent content type - "Workflow Task"
 $ParentContentType = $web.AvailableContentTypes["Workflow Task"]
     
 #Check if the content type already exists
 $ContentType = $web.ContentTypes[$ContentTypeName]
 If($ContentType -eq $NULL)
 {
     #Create new content type from  "Workflow Task" Content Type
     $ContentType = New-Object Microsoft.SharePoint.SPContentType($ParentContentType, $web.ContentTypes, $ContentTypeName)
     $ContentType.Description ="xxx"
     $ContentType.Group = "xxxx"
     $web.ContentTypes.Add($ContentType)
     $web.Update()
     Write-Host "Content Type '$ContentTypeName' Created Successfully!" -ForegroundColor Green
 }
 else
 {
     Write-Host "Content Type '$ContentTypeName' Already Exists!" -ForegroundColor Red
 }


For Reference: How to Create a Content Type in SharePoint using PowerShell?



0 Votes 0 ·
LoganathanKamalakkannan-6089 avatar image LoganathanKamalakkannan-6089 LoganathanKamalakkannan-6089 ·

Hi CaseyYangMSFT-4714,

Thanks for your answer, I have tried updating using the PowerShell but without Parent Content Type not able to create the content types, as built-in Content Types (System, Item, Task, Workflow Tasks) are missing.

Can we able to create the Built in Content Types? please advice if any

Thanks in Advance!

Best Regards,
Kamal.

0 Votes 0 ·
CaseyYangMSFT-4714 avatar image CaseyYangMSFT-4714 LoganathanKamalakkannan-6089 ·

Hi @LoganathanKamalakkannan-6089,

Is there anything has been changed before the issue occurs? It's weird that built-in content types missing.

0 Votes 0 ·