Export (0) Print
Expand All

List Element

SharePoint 2003

The List element is the top-level element that contains the entire definition of a list.

Syntax

<List
  BaseType = "Integer" | "Text"
  Default = "TRUE" | "FALSE"
  Direction = "Text"
  Description = "Text"
  DisableAttachments = "TRUE" | "FALSE"
  EventSinkAssembly = "Text"
  EventSinkClass = "Text"
  EventSinkData = "Text"
  Name = "Text"
  OrderedList = "TRUE" | "FALSE"
  PrivateList = "TRUE" | "FALSE"
  QuickLaunchUrl = URL
  RootWebOnly = "TRUE" | "FALSE"
  ThumbnailSize = Integer
  Title = "Text"
  Type = Integer
  Url = "URL"
  UrlEncode = "TRUE" | "FALSE"
  VersioningEnabled = "TRUE" | "FALSE"
  WebImageHeight = Integer
  WebImageWidth = Integer>
</List>

Attributes

NameDescription
BaseTypeOptional Text. The BaseType attribute can be set to Integer, which stores values as integers, or to Text (default), which stores values as text. Note that it is not possible to create integer base-type choice fields.
DefaultOptional Boolean. TRUE to specify that the list referenced in the ONET.XML file be created whenever a site is created. Otherwise, the list will not be created during site creation but will be available for later instantiation.
DescriptionOptional Text. Provides a description for the list. This attribute must be specified within a configuration in an ONET.XML file when adding a custom list definition to a site definition. The value of this attribute overrides the value contained with the DefaultDescription element of a SCHEMA.XML file.
DirectionRequired Text. Specifies the direction of the reading order for the list. Possible values include RTL (right-to-left), LTR (left-to-right), or none.
DisableAttachmentsOptional Boolean. TRUE to disable attachments in the list.
EventSinkAssemblyOptional Text. Specifies the strong name of a file in the Global Assembly Cache (GAC) that provides an event handler for document library events. For example, Microsoft.SharePoint, Version=11.0.0.0, Culture=Neutral, PublicKeyToken=71e9bce111e9429c. For more information, see Handling Document Library Events.
EventSinkClassOptional Text. Specifies the fully qualified, case-sensitive name of a class that defines an event handler for document library events in the form Namespace_Name.Class_Name. For more information, see Handling Document Library Events.
EventSinkDataOptional Text. Contains an arbitrary string for use by an event handler for document library events. For more information, see Handling Document Library Events.
NameRequired Text. The internal name of a list.
OrderedListOptional Boolean. TRUE to specify that the option to allow users to reorder items in the list is available on the Edit View page for the list.
PrivateListOptional Boolean. TRUE to specify that the list is private.
QuickLaunchUrlOptional Text. Specifies the URL of the view page to open for the list through Quick Launch navigation.
RootWebOnlyOptional Boolean. TRUE to specify that the list created from the definition exists only in the root Web site of a site collection.
ThumbnailSizeOptional Integer. Specifies the width of thumbnails to display in picture libraries.
TitleRequired Text. The generic display name of the list.
TypeOptional Integer. Specifies the list template type of the list. The following table lists values for the default list template types.
ValueDescription
100Generic list
101Document library
102Survey
103Links list
104Announcements list
105Contacts list
106Events list
107Tasks list
108Discussion board
109Picture library
110Data sources
111Site template gallery
113Web Part gallery
114List template gallery
115XML Form library
120Custom grid for a list
200Meeting Series list
201Meeting Agenda list
202Meeting Attendees list
204Meeting Decisions list
207Meeting Objectives list
210Meeting text box
211Meeting Things To Bring list
212Meeting Workspace Pages list
300Portal Sites list.
1100Issue tracking
2002Personal document library
2003Private document library
This attribute corresponds to the Type attribute of the ListTemplate element.
ValueDescription
100Generic list
101Document library
102Survey
103Links list
104Announcements list
105Contacts list
106Events list
107Tasks list
108Discussion board
109Picture library
110Data sources
111Site template gallery
113Web Part gallery
114List template gallery
115XML Form library
120Custom grid for a list
200Meeting Series list
201Meeting Agenda list
202Meeting Attendees list
204Meeting Decisions list
207Meeting Objectives list
210Meeting text box
211Meeting Things To Bring list
212Meeting Workspace Pages list
300Portal Sites list.
1100Issue tracking
2002Personal document library
2003Private document library
UrlOptional URL. Specifies the path to the folder in the Local_Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\60\TEMPLATE\1033\STS\LISTS directory that contains the ASPX files to which the list definition applies, relative to the root URL of the Web site.
URLEncodeOptional Boolean. TRUE to convert special characters, such as spaces, to quoted UTF-8 format, for example, %c3%ab for character ë.
VersioningEnabledOptional Boolean. TRUE to specify within a SCHEMA.XML file that versioning be enabled by default for document libraries created through the list definition. Setting this attribute has no effect on existing document libraries. If TRUE, versioning can still be disabled for a document library on the New Document Library page when the library is being created.
WebImageHeightOptional Integer. Specifies the height in pixels of an image in a picture library.
WebImageWidthOptional Integer. Specifies the width in pixels of an image in a picture library.

Element Relationships

Parent ElementsChild Elements
GlobalLists, ListFormButtons, ,ListFormOpening, Lists, Toolbar, ViewBidiHeader, ViewEmpty, ViewHeaderData, MetaData

Remarks

If List is the root element of the XML file, it must contain the Microsoft Windows SharePoint Services ows: namespace declaration. The following lines show the opening of a SCHEMA.XML file for document libraries:

<List xmlns:ows="Microsoft SharePoint" Name="Documents"
  Title="Shared Documents" Direction="0" Url="Shared Documents" BaseType="1"
  VersioningEnabled="TRUE">

Show:
© 2014 Microsoft