0

Howdie

I use a SharePoint feature to programmatic add columns to an existing content type. This content type is already assigned to a list.

After I did that, the content type has those new columns, but the list is not updated (the new columns are not shown)

I could remove the content type from that list and add it again but would lose all data saved in the old columns.

Is there any best practice to add columns to an existing content type and update the list(s) that contain that content type?

4

1 回答 1

2

MS推荐的方式是通过Object Model更新CT。请在下面找到链接。

http://msdn.microsoft.com/en-us/library/aa543504.aspx

所有列表内容类型都存储为 SharePoint Foundation 数据库中的条目,因为当您将网站内容类型添加到列表时,SharePoint Foundation 会将网站内容类型本地复制到列表中作为列表内容类型。

http://msdn.microsoft.com/en-us/library/ms442695.aspx

当您对站点内容类型进行更改时,您可以通过用户界面或通过对象模型将这些更改推送到其所有子内容类型

于 2012-09-25T11:06:24.700 回答