C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\FEATURES\Document or Picture Library\DocLib or PicLib
1. Open the schema.xml from the above location
2. Locate the “Title” field and change the sealed attribute value as Sealed="TRUE" to the tag.
Code for deleting the Title Field:-
using(SPSite siteCollection = new SPSite ("Web Application"))
{
using(SPWeb parentWeb = siteCollection.OpenWeb())
{
SPList oList = parentWeb.Lists["Document/Picture Library Name"];
SPField oField = oList.Fields["Title"]; //Column name
oField.AllowDeletion = true;
oField.Delete();
}
}
No comments:
Post a Comment