Editare

Partajați prin


SqlDataSourceView(SqlDataSource, String, HttpContext) Constructor

Definition

Initializes a new instance of the SqlDataSourceView class setting the specified SqlDataSource control as the owner of the current view.

public:
 SqlDataSourceView(System::Web::UI::WebControls::SqlDataSource ^ owner, System::String ^ name, System::Web::HttpContext ^ context);
public SqlDataSourceView (System.Web.UI.WebControls.SqlDataSource owner, string name, System.Web.HttpContext context);
new System.Web.UI.WebControls.SqlDataSourceView : System.Web.UI.WebControls.SqlDataSource * string * System.Web.HttpContext -> System.Web.UI.WebControls.SqlDataSourceView
Public Sub New (owner As SqlDataSource, name As String, context As HttpContext)

Parameters

owner
SqlDataSource

The data source control with which the SqlDataSourceView is associated.

name
String

A unique name for the data source view, within the scope of the data source control that owns it.

context
HttpContext

The current HttpContext.

Remarks

The SqlDataSourceView constructor is called by the GetView method to return a new instance of a data source view with the specified name parameter. The SqlDataSource control is associated with only one SqlDataSourceView object at any one time, and always names the view Table, although this naming restriction is imposed by the SqlDataSource control, not the SqlDataSourceView. You can override the GetView method to support views with a different naming convention.

The HttpContext object that is passed by the context parameter is used by the data source view to access parameter objects, such as the FilterParameters and SelectParameters properties.

Applies to

See also