1

There is a PnP PowerShell command called Set-PnPField which allows me to change the Group a Site Column is in.

But there does not seem to be a corresponding Set-PnPContentType to change the group a Content Type Belongs to.

Ideally I would just like to rename the group a Site Column belongs to and the group a Content Type belongs to.

I cannot seem to find a PowerShell Script to do this ?

1 Answer 1

5

Set-PnPContentType is not available via PnP PowerShell.

However, using OOTB CSOM you can modify it as below:

Connect-PnPOnline -Url "https://yoursitecollection/"
$context = Get-PnPContext

$contentType = Get-PnPContentType -Identity "Your content Type"
$contentType.Group = "Your new Group"
$contentType.Update($true)
$context.Load($contentType)
$context.ExecuteQuery()

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.