Class SfDataPager
Inheritance
Implements
Namespace: Syncfusion.UI.Xaml.Controls.DataPager
Assembly: Syncfusion.SfGrid.UWP.dll
Syntax
public class SfDataPager : Control, IDisposableConstructors
SfDataPager()
Declaration
public SfDataPager()Fields
AccentBackgroundProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.AccentBackground dependency property.
Declaration
public static readonly DependencyProperty AccentBackgroundPropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.AccentBackground dependency property.
AccentForegroundProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.AccentForeground dependency property.
Declaration
public static readonly DependencyProperty AccentForegroundPropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.AccentForeground dependency property.
AutoEllipsisModeProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.AutoEllipsisMode dependency property.
Declaration
public static readonly DependencyProperty AutoEllipsisModePropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.AutoEllipsisMode dependency property.
AutoEllipsisTextProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.AutoEllipsisText dependency property.
Declaration
public static readonly DependencyProperty AutoEllipsisTextPropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.AutoEllipsisText dependency property.
DisplayModeProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.DisplayMode dependency property.
Declaration
public static readonly DependencyProperty DisplayModePropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.DisplayMode dependency property.
NumericButtonCountProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.NumericButtonCount dependency property.
Declaration
public static readonly DependencyProperty NumericButtonCountPropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.NumericButtonCount dependency property.
NumericButtonStyleProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.NumericButtonStyle dependency property.
Declaration
public static readonly DependencyProperty NumericButtonStylePropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.NumericButtonStyle dependency property.
OrientationProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.Orientation dependency property.
Declaration
public static readonly DependencyProperty OrientationPropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.Orientation dependency property.
PageCountProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.PageCount dependency property.
Declaration
public static readonly DependencyProperty PageCountPropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.PageCount dependency property.
PagedSourceProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.PagedSource dependency property.
Declaration
public static readonly DependencyProperty PagedSourcePropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.PagedSource dependency property.
PageIndexProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.PageIndex dependency property.
Declaration
public static readonly DependencyProperty PageIndexPropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.PageIndex dependency property.
PageSizeProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.PageSize dependency property.
Declaration
public static readonly DependencyProperty PageSizePropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.PageSize dependency property.
SourceProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.Source dependency property.
Declaration
public static readonly DependencyProperty SourcePropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.Source dependency property.
UseOnDemandPagingProperty
Identifies the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.UseOnDemandPaging dependency property.
Declaration
public static readonly DependencyProperty UseOnDemandPagingPropertyField Value
| Type | 
|---|
| Windows.UI.Xaml.DependencyProperty | 
Remarks
The identifier for the Syncfusion.UI.Xaml.Controls.DataPager.SfDataPager.UseOnDemandPaging dependency property.
Properties
AccentBackground
Gets or sets the background of selected page button and navigation buttons.
Declaration
public Brush AccentBackground { get; set; }Property Value
| Type | Description | 
|---|---|
| Windows.UI.Xaml.Media.Brush | The brush that highlights the background of selected page button and navigation buttons. The default value is DarkGray. | 
AccentForeground
Gets or sets the foreground of selected page button and navigation buttons.
Declaration
public Brush AccentForeground { get; set; }Property Value
| Type | Description | 
|---|---|
| Windows.UI.Xaml.Media.Brush | The brush that highlights the foreground of selected page button and navigation buttons. The default value is White. | 
AutoEllipsisMode
Gets or sets a value that indicates how the auto ellipsis button are displayed in SfDataPager to navigate the next set of pages when PageCount is greater than the NumericButtonCount.
Declaration
public AutoEllipsisMode AutoEllipsisMode { get; set; }Property Value
| Type | Description | 
|---|---|
| AutoEllipsisMode | One of the AutoEllipsisMode enumeration that specifies how the auto ellipsis button are displayed in SfDataPager.
The default value is  | 
Remarks
When the PageCount is greater than the NumericButtonCount, auto ellipsis button will be displayed. AutoEllipsisText
AutoEllipsisText
Gets or sets the text that needs to be displayed in auto ellipsis button.
Declaration
public string AutoEllipsisText { get; set; }Property Value
| Type | Description | 
|---|---|
| System.String | The text content which needs to be displayed in the auto ellipsis button. The default value is ... | 
Remarks
When the PageCount is greater than the NumericButtonCount, you can display the auto ellipsis button by setting AutoEllipsisMode.
DisplayMode
Gets or sets a value that defines the button to be displayed in SfDataPager.
Declaration
public PageDisplayMode DisplayMode { get; set; }Property Value
| Type | Description | 
|---|---|
| PageDisplayMode | One of the  | 
Remarks
The numeric and navigation buttons can be displayed in different ways using 
EnableGridPaging
Declaration
public bool EnableGridPaging { get; set; }Property Value
| Type | 
|---|
| System.Boolean | 
NumericButtonCount
Gets or sets the number of numeric button that needs to be displayed in SfDataPager.
Declaration
public int NumericButtonCount { get; set; }Property Value
| Type | Description | 
|---|---|
| System.Int32 | Number of numeric buttons. | 
Remarks
Based on the PageSize, total number of pages will be created. If the PageCount is greater than 5, only five numeric buttons will be displayed and it can be changed by using this property.
NumericButtonStyle
Gets or sets the style applied to all the numeric button in SfDataPager.
Declaration
public Style NumericButtonStyle { get; set; }Property Value
| Type | Description | 
|---|---|
| Windows.UI.Xaml.Style | The style that is applied to all the numeric button in SfDataPager. The default value is null. | 
Remarks
To define a 
Orientation
Gets or sets a value that indicates the dimension by which child elements are stacked.
Declaration
public Orientation Orientation { get; set; }Property Value
| Type | Description | 
|---|---|
| Windows.UI.Xaml.Controls.Orientation | One of the  | 
PageCount
Gets or sets the page count when OnDemandPaging is enabled.
Declaration
public int PageCount { get; set; }Property Value
| Type | Description | 
|---|---|
| System.Int32 | Number of pages to be displayed when OnDemandPaging is enabled. The default value is zero. | 
Remarks
Specify the number of pages the data needs to populate when UseOnDemandPaging is enabled.
PagedSource
Gets or sets the collection that is used to bind the SfDataPager source to other elements.
Declaration
public PagedCollectionView PagedSource { get; set; }Property Value
| Type | Description | 
|---|---|
| PagedCollectionView | The collection that is used to bind the SfDataPager to other elements. | 
PageIndex
Gets or sets the index of selected page in SfDataPager.
Declaration
public int PageIndex { get; set; }Property Value
| Type | Description | 
|---|---|
| System.Int32 | Index of selected page in SfDataPager. The default value is zero. | 
PageSize
Gets or sets the number of records to display on a page in SfDataPager.
Declaration
public int PageSize { get; set; }Property Value
| Type | Description | 
|---|---|
| System.Int32 | The number of records to display on a single page. The default value is zero. | 
Remarks
Based on PageSize, the total number of pages will be created. When the PageSize is not specified, all the records will be displayed in a single page.
Source
Gets or sets a collection that is used to generate the content of the SfDataPager.
Declaration
public IEnumerable Source { get; set; }Property Value
| Type | Description | 
|---|---|
| System.Collections.IEnumerable | The collection that is used to generate the content of the SfDataPager. The default value is null. | 
Remarks
No need to set the Source when UseOnDemandPaging is enabled.
UseOnDemandPaging
Declaration
public bool UseOnDemandPaging { get; set; }Property Value
| Type | 
|---|
| System.Boolean | 
Methods
add_OnDemandLoading(OnDemandLoadingEventHandler)
Declaration
public void add_OnDemandLoading(OnDemandLoadingEventHandler value)Parameters
| Type | Name | Description | 
|---|---|---|
| OnDemandLoadingEventHandler | value | 
add_PageIndexChanged(PageIndexChangedEventhandler)
Declaration
public void add_PageIndexChanged(PageIndexChangedEventhandler value)Parameters
| Type | Name | Description | 
|---|---|---|
| PageIndexChangedEventhandler | value | 
add_PageIndexChanging(PageIndexChangingEventhandler)
Declaration
public void add_PageIndexChanging(PageIndexChangingEventhandler value)Parameters
| Type | Name | Description | 
|---|---|---|
| PageIndexChangingEventhandler | value | 
Dispose()
Disposes all the resources used by the 
Declaration
public void Dispose()Dispose(Boolean)
Disposes all the resources used by the 
Declaration
protected virtual void Dispose(bool isDisposing)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Boolean | isDisposing | Indicates whether the call is from Dispose method or from a finalizer. | 
LoadDynamicItems(Int32, IEnumerable)
Loads the ItemsSource for corresponding page.
Declaration
public void LoadDynamicItems(int startIndex, IEnumerable items)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Int32 | startIndex | Index based on PageIndex which is ( Number of previous pages * PageSize). | 
| System.Collections.IEnumerable | items | ItemsSource to load | 
Remarks
This method can be used when OnDemandPaging technique is used to load the data.
MoveToFirstPage()
Navigate to the first page.
Declaration
public void MoveToFirstPage()MoveToLastPage()
Navigate to the last page.
Declaration
public void MoveToLastPage()MoveToNextPage()
Move to the next page.
Declaration
public void MoveToNextPage()MoveToPage(Int32)
Navigate to the particular page based on PageIndex.
Declaration
public void MoveToPage(int pageIndex)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Int32 | pageIndex | Index of the page to be navigate. | 
MoveToPreviousPage()
Navigate to the previous page.
Declaration
public void MoveToPreviousPage()OnApplyTemplate()
Declaration
protected override void OnApplyTemplate()OnKeyDown(KeyRoutedEventArgs)
Declaration
protected override void OnKeyDown(KeyRoutedEventArgs e)Parameters
| Type | Name | Description | 
|---|---|---|
| Windows.UI.Xaml.Input.KeyRoutedEventArgs | e | 
OnManipulationCompleted(ManipulationCompletedRoutedEventArgs)
Declaration
protected override void OnManipulationCompleted(ManipulationCompletedRoutedEventArgs e)Parameters
| Type | Name | Description | 
|---|---|---|
| Windows.UI.Xaml.Input.ManipulationCompletedRoutedEventArgs | e | 
OnManipulationStarted(ManipulationStartedRoutedEventArgs)
Declaration
protected override void OnManipulationStarted(ManipulationStartedRoutedEventArgs e)Parameters
| Type | Name | Description | 
|---|---|---|
| Windows.UI.Xaml.Input.ManipulationStartedRoutedEventArgs | e | 
OnPointerEntered(PointerRoutedEventArgs)
Declaration
protected override void OnPointerEntered(PointerRoutedEventArgs e)Parameters
| Type | Name | Description | 
|---|---|---|
| Windows.UI.Xaml.Input.PointerRoutedEventArgs | e | 
OnPointerExited(PointerRoutedEventArgs)
Declaration
protected override void OnPointerExited(PointerRoutedEventArgs e)Parameters
| Type | Name | Description | 
|---|---|---|
| Windows.UI.Xaml.Input.PointerRoutedEventArgs | e | 
remove_OnDemandLoading(OnDemandLoadingEventHandler)
Declaration
public void remove_OnDemandLoading(OnDemandLoadingEventHandler value)Parameters
| Type | Name | Description | 
|---|---|---|
| OnDemandLoadingEventHandler | value | 
remove_PageIndexChanged(PageIndexChangedEventhandler)
Declaration
public void remove_PageIndexChanged(PageIndexChangedEventhandler value)Parameters
| Type | Name | Description | 
|---|---|---|
| PageIndexChangedEventhandler | value | 
remove_PageIndexChanging(PageIndexChangingEventhandler)
Declaration
public void remove_PageIndexChanging(PageIndexChangingEventhandler value)Parameters
| Type | Name | Description | 
|---|---|---|
| PageIndexChangingEventhandler | value | 
UnWireEvents()
Declaration
public void UnWireEvents()WireEvents()
Declaration
public void WireEvents()Events
OnDemandLoading
Occurs when the pager moves to corresponding page and load the data in on-demand.
Declaration
public event OnDemandLoadingEventHandler OnDemandLoadingEvent Type
| Type | 
|---|
| OnDemandLoadingEventHandler | 
Remarks
PageIndexChanged
Occurs once the pages are navigated.
Declaration
public event PageIndexChangedEventhandler PageIndexChangedEvent Type
| Type | 
|---|
| PageIndexChangedEventhandler | 
PageIndexChanging
Occurs while navigating between the pages.
Declaration
public event PageIndexChangingEventhandler PageIndexChangingEvent Type
| Type | 
|---|
| PageIndexChangingEventhandler | 
Remarks
Page navigation can be skipped by using PageIndexChanging event.