wpf-devexpress-dot-xpf-dot-data-dot-pagedasyncsource-5d063e48.md
Allows you to fetch page rows.
Namespace : DevExpress.Xpf.Data
Assembly : DevExpress.Xpf.Core.v25.2.dll
NuGet Package : DevExpress.Wpf.Core
public event EventHandler<FetchPageAsyncEventArgs> FetchPage
Public Event FetchPage As EventHandler(Of FetchPageAsyncEventArgs)
The FetchPage event's data class is FetchPageAsyncEventArgs. The following properties provide information specific to this event:
| Property | Description |
|---|---|
| Filter | Gets the GridControl filtering. Inherited from FetchEventArgsBase. |
| Keys | Gets keys that you passed to the ReloadRows(Object[]) method. |
| Result | Gets or sets the result of the fetch page operation. |
| Skip | Gets the number of rows to skip in a returned result set. Inherited from FetchEventArgsBase. |
| SkipToken | Gets the skip token. Inherited from FetchEventArgsBase. |
| SortOrder | Gets the GridControl‘s sorting. Inherited from FetchEventArgsBase. |
| Take | Gets the number of rows to take in a returned result set. Inherited from FetchPageEventArgsBase. |
View Example: How to Bind to PagedAsyncSource
If you want to maintain a clean MVVM pattern and specify a fetch operation in a ViewModel, create a command and bind it to the PagedAsyncSource.FetchPageCommand property.
The following code snippets (auto-collected from DevExpress Examples) contain references to the FetchPage event.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
how-to-bind-wpf-grid-to-data/CS/CodeBehind/EFCore/PagedAsyncSource/MainWindow.xaml.cs#L21
};
source.FetchPage += OnFetchPage;
source.GetTotalSummaries += OnGetTotalSummaries;
wpf-data-grid-implement-crud-operations/CS/CodeBehind/EFCore/PagedAsyncSource/MainWindow.xaml.cs#L21
};
source.FetchPage += OnFetchPage;
source.GetTotalSummaries += OnGetTotalSummaries;
wpf-data-grid-bind-to-pagedasyncsource/CS/PagedAsyncSourceSample/MainWindow.xaml.cs#L22
source.FetchPage += (o, e) => {
e.Result = FetchRowsAsync(e);
wpf-data-grid-use-skip-tokens-to-optimize-paging/CS/MainWindow.xaml.cs#L21
};
source.FetchPage += (o, e) => {
e.Result = FetchRowsAsync(e);
how-to-bind-wpf-grid-to-data/VB/CodeBehind/EFCore/PagedAsyncSource/MainWindow.xaml.vb#L18
}
AddHandler source.FetchPage, AddressOf OnFetchPage
AddHandler source.GetTotalSummaries, AddressOf OnGetTotalSummaries
wpf-data-grid-bind-to-pagedasyncsource/VB/PagedAsyncSourceSample/MainWindow.xaml.vb#L18
AddHandler Unloaded, Sub(o, e) source.Dispose()
AddHandler source.FetchPage, Sub(o, e) e.Result = FetchRowsAsync(e)
AddHandler source.GetUniqueValues, Sub(o, e)
wpf-data-grid-use-skip-tokens-to-optimize-paging/VB/MainWindow.xaml.vb#L16
AddHandler Unloaded, Sub(o, e) source.Dispose()
AddHandler source.FetchPage, Sub(o, e) e.Result = FetchRowsAsync(e)
Me.grid.ItemsSource = source
See Also