संपादित करें

इसके माध्यम से साझा किया गया


DataSourceControl.IDataSource.GetView(String) Method

Definition

Gets the named DataSourceView object associated with the DataSourceControl control. Some data source controls support only one view, while others support more than one.

 virtual System::Web::UI::DataSourceView ^ System.Web.UI.IDataSource.GetView(System::String ^ viewName) = System::Web::UI::IDataSource::GetView;
System.Web.UI.DataSourceView IDataSource.GetView (string viewName);
abstract member System.Web.UI.IDataSource.GetView : string -> System.Web.UI.DataSourceView
override this.System.Web.UI.IDataSource.GetView : string -> System.Web.UI.DataSourceView
Function GetView (viewName As String) As DataSourceView Implements IDataSource.GetView

Parameters

viewName
String

The name of the DataSourceView to retrieve. In data source controls that support only one view, such as SqlDataSource, this parameter is ignored.

Returns

Returns the named DataSourceView associated with the DataSourceControl.

Implements

Exceptions

viewName is null.

Remarks

The viewName parameter is ignored when this method is called on data source controls that support only one view, such as the SqlDataSource and AccessDataSource controls.

Note

The DataSourceControl class's default implementation, which is called by this interface method, returns null. If you extend the DataSourceControl class, override the GetView method to return the specified DataSourceView object.

Applies to

See also