IListSource.ContainsListCollection 属性

定义

获取一个值,该值指示集合是否为对象的集合 IList

public:
 property bool ContainsListCollection { bool get(); };
public bool ContainsListCollection { get; }
member this.ContainsListCollection : bool
Public ReadOnly Property ContainsListCollection As Boolean

属性值

如果集合是对象的集合 ,则为

示例

下面的代码示例演示如何实现 IListSource 接口。 命名EmployeeListSource的组件指示它不包含IListContainsListCollection方法返回false的数据绑定。 有关完整代码列表,请参阅 “如何:实现 IListSource 接口”。

bool IListSource.ContainsListCollection => false;
Public ReadOnly Property ContainsListCollection() As Boolean Implements System.ComponentModel.IListSource.ContainsListCollection
    Get
        Return False
    End Get
End Property

注解

在返回true中使用DataSet此属性是因为DataSet类包含集合集合。 在返回false中使用DataTable此属性是因为DataTable类包含对象的集合。

适用于

另请参阅