DataColumn 成员

表示 DataTable 中列的架构。

下表列出了由 DataColumn 类型公开的成员。

公共构造函数

  名称 说明
Public method Supported by the .NET Compact Framework DataColumn 已重载。初始化 DataColumn 类的新实例。

页首

公共属性

(请参见 受保护的属性 )

  名称 说明
Public property Supported by the .NET Compact Framework AllowDBNull 获取或设置一个值,该值指示对于属于该表的行,此列中是否允许空值。
Public property Supported by the .NET Compact Framework AutoIncrement 获取或设置一个值,该值指示对于添加到该表中的新行,列是否将列的值自动递增。
Public property Supported by the .NET Compact Framework AutoIncrementSeed 获取或设置其 AutoIncrement 属性设置为 true 的列的起始值。
Public property Supported by the .NET Compact Framework AutoIncrementStep 获取或设置其 AutoIncrement 属性设置为 true 的列使用的增量。
Public property Supported by the .NET Compact Framework Caption 获取或设置列的标题。
Public property Supported by the .NET Compact Framework ColumnMapping 获取或设置列的 MappingType
Public property Supported by the .NET Compact Framework ColumnName 获取或设置 DataColumnCollection 中的列的名称。
Public property Supported by the .NET Compact Framework Container  获取组件的容器。(从 MarshalByValueComponent 继承。)
Public property Supported by the .NET Compact Framework DataType 获取或设置存储在列中的数据的类型。
Public property Supported by the .NET Compact Framework DateTimeMode 获取或设置列的 DateTimeMode
Public property Supported by the .NET Compact Framework DefaultValue 在创建新行时获取或设置列的默认值。
Public property Supported by the .NET Compact Framework DesignMode  获取指示组件当前是否处于设计模式的值。(从 MarshalByValueComponent 继承。)
Public property Supported by the .NET Compact Framework Expression 获取或设置表达式,用于筛选行、计算列中的值或创建聚合列。
Public property Supported by the .NET Compact Framework ExtendedProperties 获取与 DataColumn 相关的自定义用户信息的集合。
Public property Supported by the .NET Compact Framework MaxLength 获取或设置文本列的最大长度。
Public property Supported by the .NET Compact Framework Namespace 获取或设置 DataColumn 的命名空间。
Public property Supported by the .NET Compact Framework Ordinal 获取列在 DataColumnCollection 集合中的位置。
Public property Supported by the .NET Compact Framework Prefix 获取或设置一个 XML 前缀,该前缀是 DataTable 的命名空间的别名。
Public property Supported by the .NET Compact Framework ReadOnly 获取或设置一个值,该值指示一旦向表中添加了行,列是否还允许更改。
Public property Supported by the .NET Compact Framework Site  获取或设置组件的位置。(从 MarshalByValueComponent 继承。)
Public property Supported by the .NET Compact Framework Table 获取列所属的 DataTable
Public property Supported by the .NET Compact Framework Unique 获取或设置一个值,该值指示列的每一行中的值是否必须是唯一的。

页首

受保护的属性

  名称 说明
Protected property Supported by the .NET Compact Framework Events  获取附加到该组件的事件处理程序的列表。(从 MarshalByValueComponent 继承。)

页首

公共方法

(请参见 受保护的方法 )

  名称 说明
Public method Supported by the .NET Compact Framework Dispose  已重载。 释放由 MarshalByValueComponent 占用的资源。 (从 MarshalByValueComponent 继承。)
Public method Supported by the .NET Compact Framework Equals  已重载。 确定两个 Object 实例是否相等。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework GetHashCode  用作特定类型的哈希函数。GetHashCode 适合在哈希算法和数据结构(如哈希表)中使用。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework GetService  获取 IServiceProvider 的实施者。 (从 MarshalByValueComponent 继承。)
Public method Supported by the .NET Compact Framework GetType  获取当前实例的 Type。 (从 Object 继承。)
Public method Static Supported by the .NET Compact Framework ReferenceEquals  确定指定的 Object 实例是否是相同的实例。 (从 Object 继承。)
Public method Supported by the .NET Compact Framework SetOrdinal DataColumn 的序号或位置更改为指定的序号或位置。
Public method Supported by the .NET Compact Framework ToString 已重写。 获取列的 Expression(如果存在的话)。

页首

受保护的方法

  名称 说明
Protected method Supported by the .NET Compact Framework CheckNotAllowNull 该成员支持 .NET Framework 结构,不应从代码直接使用。
Protected method Supported by the .NET Compact Framework CheckUnique 该成员支持 .NET Framework 结构,不应从代码直接使用。
Protected method Supported by the .NET Compact Framework Dispose  已重载。 释放由 MarshalByValueComponent 占用的资源。 (从 MarshalByValueComponent 继承。)
Protected method Supported by the .NET Compact Framework Finalize  [待提供。] (从 MarshalByValueComponent 继承。)
Protected method Supported by the .NET Compact Framework MemberwiseClone  创建当前 Object 的浅表副本。 (从 Object 继承。)
Protected method Supported by the .NET Compact Framework OnPropertyChanging 该成员支持 .NET Framework 结构,不应从代码直接使用。
Protected method Supported by the .NET Compact Framework RaisePropertyChanging 该成员支持 .NET Framework 结构,不应从代码直接使用。

页首

公共事件

  名称 说明
Public event Supported by the .NET Compact Framework Disposed  添加事件处理程序以侦听组件上的 Disposed 事件。(从 MarshalByValueComponent 继承。)

页首

请参见

参考

DataColumn 类
System.Data 命名空间
Add
DataColumnCollection
Constraints
ConstraintCollection 类
System.Windows.Forms.DataGrid
DataRow
DataTable
DataSet
NewRow
DataRowCollection
UniqueConstraint