SPBuiltInFieldId.Comment-Feld
Gibt ein Feld, das die Kommentare enthält, die dem angegebenen SharePoint Foundation -Objekt zugeordnet sind.
Namespace: Microsoft.SharePoint
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'Declaration
Public Shared ReadOnly Comment As Guid
'Usage
Dim value As Guid
value = SPBuiltInFieldId.Comment
public static readonly Guid Comment
Beispiele
SPSite oSiteCollection = SPContext.Current.Site;
SPWebCollection collWebsites = siteCollection.AllWebs;
foreach (SPWeb oWebsite in collWebsites)
{
SPListCollecion collLists = oWebsite.Lists;
foreach (SPList oList in lists
{
if (oList.BaseType == SPBaseType.DocumentLibrary)
{
SPDocumentLibrary oDocumentLibrary = (SPDocumentLibrary)oList;
if (!oDocumentLibrary.IsCatalog && oList.BaseTemplate !=
SPListTemplateType.XMLForm)
{
SPField siteCommentGuid =
oDocumentLibrary.Fields[SPBuiltInFieldId.Comment);
SPFieldLink link = new SPFieldLink(siteColumn);
SPContentType anncOnList =
taskList.ContentTypes[anncType.Name];
anncOnList = taskList.ContentTypes[anncType.Name];
anncOnList.FieldLinks[anncOnList.FieldLinks.Count - 1].Name
}
}
oWebsite.Dispose();
}
Hinweis
Bestimmte Objekte, die IDisposable -Schnittstelle implementieren, und Sie müssen vermeiden, diese Objekte im Arbeitsspeicher beibehalten, wenn sie nicht mehr benötigt werden. Informationen zu bewährten Codierung finden Sie unter Disposing Objects.