SharePointOnline multiline column ShowInDisplayForm fails

Copper Contributor

Hello,

i have a contenttype which uses a multiline column for approval comments. This column should be hidden in the new form and the edit form, because it is filled with content by a workflow.

But when i set ShowInNewForm and ShowInEditForm to false, the column is not shown in the display form. I have to set ShowInEditForm to true to see the column in the DisplayForm.

I use PnP to get and set  the contenttype

$ListContentType = Get-PnPContentType -list "Technology" -Identity "TechContenttype"
$ContentTypeFields = Get-PnPProperty -ClientObject $ListContentType -Property Fields

$ctx = get-PnPContext
$field.SetShowInNewForm($false)
$field.SetShowInEditForm($false)
$field.Update()
$ListContentType.Update($false)
$ctx.ExecuteQuery()

 

Thanks for help,

Lutz

0 Replies