R2 2018 Release is here – now with modern UI for chatbots and more! See what’s new!
Change Theme

SASS Themes

    LESS Themes

      SASS Theme Builder

      Create new or customize SASS themes
      Launch Theme Builder

      Grid / Pager Visibility

      Configure

      Description

      It often turns out that all items in the ASP.NET Core Grid can fit into a single page and then showing the pager might not be necessary.

      The Telerik for ASP.NET Core DataGrid toggles the pager visibility using the .Pageable(pager=>pager.AlwaysVisible(true)) method. By default the gridview will show the pager even when the total amount of items in the DataSource is less than the PageSize.

      If value is set to false the behavior will be as follows:

      • When the total amount of items initially set in the DataSource is less than the PageSize number the pager will be hidden.
      • When the total amount of items initially set in the DataSource is greater than or equal to the PageSize number the pager will be shown.
      • When the total amount of items in the DataSource becomes less than the PageSize number (after delete, filter operation or PageSize change) the pager will be hidden.
      • When the total amount of items in the DataSource becomes greater than or equal to the PageSize number (after an insert, filter operation or PageSize change) the pager will be shown.

      In the demo alwaysVisible checkbox enables/disables the pageable.alwaysVisible option for the grid.

      More about Telerik Grid for ASP.NET Core

      ASP.NET Core source

      Also available for:

      • pager_visibility.cshtml
      • Pager_VisibilityController.cs

      Support & learning resources

      Grid for other technologies