列表库数据类型

Optional. The data type of the field. The types listed in the following table are available.

Attachments

Stores the URLs for attachments.

Boolean

Used to store a TRUE/FALSE value (stored in the database as 0 or 1). This field is sortable and groupable.

Choice

Allows the user to specify a predetermined set of values that can be used to enter data into the field. The Choice and Lookup types are the most important fields for sorting and grouping. The BaseType and Format attributes can be used for choice fields. This field is sortable and groupable.

When a value is given for a choice option, then that value is used as the submitted value for the field selection. When no value is given, that choice is submitted as the text value of the choice. In all cases, the text value of the choice is what is displayed in the UI (drop-down list or radio button text). The order in which choices appear in the editing UI is always the order that items are specified within the CHOICES element.

Use the MultiChoice type to specify a Choice field that implements check boxes and allows the user to select multiple values.

Computed

Specifies a field that depends on another field for its contents. For example, a LinkTitleNoMenu field amounts to surrounding a Title field value with a hyperlink.

Counter

Generally only used for the internal ID field. Its integer value is set automatically to be unique with respect to every other item in the current list. The Counter type is always read-only and cannot be set via a form post. This field is sortable but not groupable.

CrossProjectLink

Used to connect an event in a SharePoint list with a Meeting Workspace site and refers specifically to the field type of the checkbox used in New and Edit Item forms to create a Meeting Workspace site for the item.

Currency

Allows for a currency value to be entered. Each currency field is tied to a specific locale’s currency. In all other respects, it is treated like the Number field type. Use the LCID attribute to indicate a currency of a specific locale. The Decimals, Max, and Min attributes can be used for currency types. This field is sortable and groupable.

DateTime

Allows for storage of a fully qualified date or time of day. Use the Format attribute to specify date formatting, and use the StorageTZ attribute to determine how date/time values are stored. This field is sortable and groupable.

For Display mode, the order of date formatting derives from the regional settings (“M/D/Y” or “D/M/Y”). In Edit mode (or in New mode for Default element value), date/times are rendered in universal format: M/D/Y hh:mm am/pm.

File

Contains a file.

Guid

Allows for globally unique identifiers (GUIDs).

Integer

Allows for positive or negative integer values. The Commas and NegativeFormat attributes are used to specify integer formatting.

Lookup

Behaves very similarly to a Choice field, except that the available options come from another list rather than being a hard-coded selection of values. The List and ShowField attributes can be used for Lookup fields. This field is sortable and groupable. For sorting and grouping, use the DisplayField value (Title, by default) rather than the foreign key stored in the list.

ModStat

Contains content approval status. Possible values include Approved (default), Rejected, and Pending (stored in the database as 0, 1, or 2, respectively).

MultiChoice

Specifies a Choice field that implements check boxes and allows the user to select multiple values.

Note

Allows users to enter multiple lines of text. This field is neither sortable nor groupable.

All text is defined to be straight ASCII without HTML markup. Anything that looks like HTML markup or a URL is just quoted (for example, Server.HTMLEncode) to look like straight text. The control for editing this format is a simple TEXTAREA block. Use the NumLines attribute to specify the number of lines to display.

Number

Allows for a floating point number to be entered. This field is sortable and groupable.

Numbers entered are parsed according to the current locale settings for decimal points and thousand separators. Negative numbers can be indicated by wrapping them in parentheses or by using a negative symbol.

The following attributes can be used in conjunction with the Number attribute to specify number formatting: Decimals, Div, Max, Min, Mult, and Percentage.

Recurrence

Used to edit and define the recurrence pattern for an item in an events list.

Text

A single line of text entered in an edit box. This field is sortable and groupable. Use the MaxLength attribute to set a maximum number of characters allowed.

Threading

The Threading field type is used in the creation and display of threaded discussion-like views. Any list can contain a threading column, but a special UI is generated when it is used. (It is never displayed as a standard editable field in a form nor as a normal column in a view.)

If a sort is performed on a threading field, a pre-order traversal of all the records in a parent-child relationship is returned. This is accomplished by saving the concatenation of the creation date and ID number of all the parent records of a particular record.

URL

Used to create a freeform hyperlink.

A URL field is displayed as <A HREF="URL">Description</A>. If no description is given, it is displayed as <A HREF="URL">URL</A>.

The URL text is itself stored in the URLs (DocMd) table, which stores all the URLs in Microsoft SharePoint databases on the server. This is done so that any URLs that are local on the server can be updated via link fix-up when their destination moves.

When a record with a URL field contained within it is deleted, the corresponding referenced record from the URL table is also deleted.

This field is sortable and groupable. (The sort is defined according to the textual description rather than the contents of the URL; if no description is given, it sorts the same as blank.)

When Type is URL, the LinkType attribute can be used to specify the type of link.

User

A Lookup field that references the UserInfo database table.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值