Skip to main content
All docs
V24.2

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

DxTreeList.PagerSwitchToInputBoxButtonCount Property

Specifies the total number of pages when the pager switches from numeric buttons to the input box in Auto mode.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

#Declaration

C#
[DefaultValue(11)]
[Parameter]
public int PagerSwitchToInputBoxButtonCount { get; set; }

#Property Value

Type Default Description
Int32 11

The total number of pages when the pager switches to the input box.

#Remarks

When the PagerNavigationMode property is set to Auto (the default value), the pager displays the input box in the following cases:

  • The total number of pages is greater than or equal to the PagerSwitchToInputBoxButtonCount value.
  • The TreeList is displayed on small devices. In this case, the PagerSwitchToInputBoxButtonCount value is ignored.

In other cases, the pager displays numeric buttons.

The following example enables the input box when the total number of pages is greater than or equal to 5:

@inject EmployeeTaskService EmployeeTaskService

<DxTreeList Data="TreeListData"
            KeyFieldName="Id"
            ParentKeyFieldName="ParentId"
            PageSize="5"
            PagerSwitchToInputBoxButtonCount="5"
            PageSizeSelectorVisible="true"
            PageSizeSelectorItems="@(new int[] { 5, 10, 15 })">
    <Columns>
        <DxTreeListDataColumn FieldName="Name" Caption="Task" />
        <DxTreeListDataColumn FieldName="EmployeeName" />
        <DxTreeListDataColumn FieldName="StartDate" />
        <DxTreeListDataColumn FieldName="DueDate" />
    </Columns>
</DxTreeList>

@code {
    List<EmployeeTask> TreeListData { get; set; }

    protected override void OnInitialized() {
        TreeListData = EmployeeTaskService.GenerateData();
    }
}

Blazor TreeList Pager Switch to Input Box

Run Demo: TreeList - Paging

For more information about paging in the TreeList component, refer to the following topic: Paging in Blazor TreeList.

See Also