DetailsView.InitializePager(DetailsViewRow, PagedDataSource) 方法

定义

DetailsView 控件创建页导航行。Creates the pager row for the DetailsView control.

protected:
 virtual void InitializePager(System::Web::UI::WebControls::DetailsViewRow ^ row, System::Web::UI::WebControls::PagedDataSource ^ pagedDataSource);
protected virtual void InitializePager (System.Web.UI.WebControls.DetailsViewRow row, System.Web.UI.WebControls.PagedDataSource pagedDataSource);
abstract member InitializePager : System.Web.UI.WebControls.DetailsViewRow * System.Web.UI.WebControls.PagedDataSource -> unit
override this.InitializePager : System.Web.UI.WebControls.DetailsViewRow * System.Web.UI.WebControls.PagedDataSource -> unit

参数

row
DetailsViewRow

包含当前页导航行的 DetailsViewRowThe DetailsViewRow that contains the pager row.

pagedDataSource
PagedDataSource

包含当前页的数据的 PagedDataSourceA PagedDataSource that contains the data for the current page.

注解

InitializePager方法是DetailsView由控件调用以创建页导航行的帮助器方法。The InitializePager method is a helper method called by the DetailsView control to create the pager row. 它使用TableCell 参数pagedDataSource中包含的PagedDataSource对象的属性创建一个包含导航控件的对象。It creates a TableCell object that contains the navigation controls using the properties of the PagedDataSource object contained in the pagedDataSource parameter. 然后, 将单元添加到row参数所指定的行。The cell is then added to the row specified by the row parameter.

继承者说明

扩展DetailsView类时, 可以重写此方法以创建自己的页导航行。When extending the DetailsView class, you can override this method to create your own pager row.

适用于

另请参阅