|
| 1 | +--- |
| 2 | +layout: post |
| 3 | +title: Behaviour Settings in Blazor Pager Component | Syncfusion |
| 4 | +description: Checkout here and learn about all the basic functionalities of rendering the Syncfusion Blazor Pager component and much more. |
| 5 | +platform: Blazor |
| 6 | +control: Pager |
| 7 | +documentation: ug |
| 8 | +--- |
| 9 | + |
| 10 | +# Behaviour Settings in Pager Component |
| 11 | + |
| 12 | +This section briefly explains how the Pager API's are helped to render the elements (numeric items and navigation buttons) of the Pager component. The total pages of the Pager component is calculated based on the defined [PageSize](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Navigations.SfPager.html#Syncfusion_Blazor_Navigations_SfPager_PageSize) and [TotalItemsCount](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Navigations.SfPager.html#Syncfusion_Blazor_Navigations_SfPager_TotalItemsCount) property. |
| 13 | + |
| 14 | +## Page size |
| 15 | + |
| 16 | +The Pager component provides an option to define the number of items to be displayed per page. This can be achieved by using the [PageSize](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Navigations.SfPager.html#Syncfusion_Blazor_Navigations_SfPager_PageSize) property. The default value of the `PageSize` property is "12." |
| 17 | + |
| 18 | +```csharp |
| 19 | +@using Syncfusion.Blazor.Navigations |
| 20 | + |
| 21 | +<SfPager PageSize="5" TotalItemsCount="20"> |
| 22 | +</SfPager> |
| 23 | + |
| 24 | +``` |
| 25 | + |
| 26 | +## Numeric items count |
| 27 | + |
| 28 | +The Pager component provides an option to define the number of numeric items to be displayed in the Pager for navigation. This can be achieved by using the [NumericItemsCount](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Navigations.SfPager.html#Syncfusion_Blazor_Navigations_SfPager_NumericItemsCount) property. The default value of the `NumericItemsCount` property is "10." |
| 29 | +
|
| 30 | +```csharp |
| 31 | +@using Syncfusion.Blazor.Navigations |
| 32 | + |
| 33 | +<SfPager NumericItemsCount="5" TotalItemsCount="20" PageSize="4"> |
| 34 | +</SfPager> |
| 35 | + |
| 36 | +``` |
| 37 | + |
| 38 | +## Total items count |
| 39 | + |
| 40 | +The Pager component provides an option to define the total number of items available in the assigned data collection, which is used to render the elements(numeric items, navigation buttons) of Pager component. This can be achieved by using the [TotalItemsCount](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Navigations.SfPager.html#Syncfusion_Blazor_Navigations_SfPager_TotalItemsCount) property of the Pager. |
| 41 | +
|
| 42 | +```csharp |
| 43 | +@using Syncfusion.Blazor.Navigations |
| 44 | + |
| 45 | +<SfPager TotalItemsCount="75"> |
| 46 | +</SfPager> |
| 47 | + |
| 48 | +``` |
| 49 | + |
| 50 | +## Current page |
| 51 | + |
| 52 | +Blazor Pager component support to define which page to be displayed currently in the Pager using the [CurrentPage](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Navigations.SfPager.html#Syncfusion_Blazor_Navigations_SfPager_CurrentPage) property. The default value of the `CurrentPage` property is "1". |
| 53 | +
|
| 54 | +```csharp |
| 55 | +@using Syncfusion.Blazor.Navigations |
| 56 | + |
| 57 | +<SfPager CurrentPage="3" TotalItemsCount="20" PageSize="4" NumericItemsCount="5"> |
| 58 | +</SfPager> |
| 59 | + |
| 60 | +``` |
| 61 | + |
| 62 | +## Show pager message |
| 63 | + |
| 64 | +The Pager component provides an option to show or hide the Pager information in the Pager container. This can be achieved by using the [ShowPagerMessage](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Navigations.SfPager.html#Syncfusion_Blazor_Navigations_SfPager_ShowPagerMessage) property. The default value of the `ShowPagerMessage` is **true**. Setting `ShowPagerMessage` to **false** hides the Pager information. |
| 65 | +
|
| 66 | +```csharp |
| 67 | +@using Syncfusion.Blazor.Navigations |
| 68 | + |
| 69 | +<SfPager ShowPagerMessage="true" PageSize="4" NumericItemsCount="5" TotalItemsCount="20"> |
| 70 | +</SfPager> |
| 71 | + |
| 72 | +``` |
| 73 | + |
| 74 | + |
0 commit comments