DataSourceControl.IDataSource.GetViewNames DataSourceControl.IDataSource.GetViewNames DataSourceControl.IDataSource.GetViewNames Method

定义

获取名称的集合,表示与 DataSourceControl 控件关联的 DataSourceView 对象的列表。Gets a collection of names, representing the list of DataSourceView objects associated with the DataSourceControl control.

 virtual System::Collections::ICollection ^ System.Web.UI.IDataSource.GetViewNames() = System::Web::UI::IDataSource::GetViewNames;
System.Collections.ICollection IDataSource.GetViewNames ();
Function GetViewNames () As ICollection Implements IDataSource.GetViewNames

返回

ICollection,包含与 DataSourceControl 关联的 DataSourceView 对象的名称。An ICollection that contains the names of the DataSourceView objects associated with the DataSourceControl.

实现

注解

备注

此接口方法调用的null类的默认实现将返回,这表示仅支持一个视图。DataSourceControlThe DataSourceControl class's default implementation, which is called by this interface method, returns null, which indicates that only one view is supported. 如果扩展DataSourceControl类, 请GetViewNames重写方法以返回视图名称的集合。If you extend the DataSourceControl class, override the GetViewNames method to return a collection of view names. 可以将名称传递给GetView方法以DataSourceView返回对象。A name can be passed to the GetView method to return a DataSourceView object.

适用于

另请参阅