SPFieldCollection Methods

Include Protected Members
Include Inherited Members

The SPFieldCollection type exposes the following members.

Methods

  Name Description
Add(SPField) Adds a field to the collection based on the specified field.
Add(String, SPFieldType, Boolean) Creates a field in the collection based on the specified display name, field type, and Boolean value.
Add(String, SPFieldType, Boolean, Boolean, StringCollection) Creates a field in the collection based on the specified display name, field type, Boolean values for other field properties, and choices in the case of a Choice field.
AddFieldAsXml(String) Creates a field based on the specified schema.
AddFieldAsXml(String, Boolean, SPAddFieldOptions) Creates a field based on the specified schema, Boolean value, and field options.
AddLookup(String, Guid, Boolean) Creates a lookup field in the collection of fields for a list, based on the specified display name, lookup list identifier (ID), and a Boolean value that specifies whether the field is required. A lookup field refers to values from a field in another list.
AddLookup(String, Guid, Guid, Boolean) Creates a lookup field in the collection of fields for a list based on the specified display name, lookup list identifier (ID), Web site ID, and a Boolean value that specifies whether the field is required. A lookup field refers to values from a field in another list.
AddSPFieldCreatorDelegate Adds a callback to the list of callbacks that is associated with the fields in the SPFieldCollection that is maintained for multithreading and asynchronous communications.
ContainsField Returns a Boolean value that indicates whether the collection contains the specified field.
CreateNewField Creates a field based on the specified type name and display name.
Delete Deletes the field with the specified internal name from the collection.
Equals (Inherited from Object.)
Finalize (Inherited from Object.)
GetField Returns the field with the specified internal name or display name from the collection.
GetFieldByInternalName Returns the field with the specified internal name from the collection.
GetHashCode (Inherited from Object.)
GetObjectData Retrieves the data required to serialize the object. (Inherited from SPAutoSerializingObject.)
GetType (Inherited from Object.)
MemberwiseClone (Inherited from Object.)
OnDeserialization Called after the object has been deserialized from the file system cache or the database. (Inherited from SPAutoSerializingObject.)
ToString (Inherited from Object.)
UpdateParent Causes the containing SPPersistedObject, if one exists, to update its state. (Inherited from SPAutoSerializingObject.)

Top

Explicit Interface Implementations

  Name Description
ICollection.CopyTo (Inherited from SPBaseCollection.)
IEnumerable.GetEnumerator (Inherited from SPBaseCollection.)

Top

See Also

Reference

SPFieldCollection Class

Microsoft.SharePoint Namespace