共用方式為


排序和分頁 (EntityDataSource)

更新:2007 年 11 月

EntityDataSource 控制項支援自動排序與分頁查詢傳回的資料。EntityDataSource 控制項的 AutoPage() 與 AutoSort() 屬性為布林值,指出是否啟用了資料繫結控制項的分頁與排序。這些屬性設定為 true 時,EntityDataSource 控制項會根據資料繫結控制項提供給 EntityDataSourceView 的資訊,將適當的查詢產生器方法加入到 ObjectQuery<T>

AutoPage() 屬性的值會判斷 EntityDataSourceView 控制項的 CanPage 屬性為 true 或 false。AutoSort() 屬性的值會判斷 EntityDataSourceView 控制項的 CanSortCanRetrieveTotalRowCount 屬性為 true 或 false。

請參閱

概念

設定 EntityDataSource 控制項

排序結果 (EntityDataSource)

EntityDataSource 設計工具

自訂命令文字 (EntityDataSource)

其他資源

以物件形式查詢資料 (Entity Framework)