Skip to main content
All docs
V24.2

DxTreeList.GetStartRowVisibleIndex() Method

Gets the visible index of the first row on the current page.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

Declaration

public int GetStartRowVisibleIndex()

Returns

Type Description
Int32

The row’s visible index.

Remarks

The following code snippet displays the visible index of the first row on the current TreeList page:

@inject EmployeeTaskService EmployeeTaskService

<DxTreeList @ref="MyTreeList"
            Data="TreeListData"
            KeyFieldName="Id"
            ParentKeyFieldName="ParentId"
            PageIndexChanged="TreeList_PageIndexChanged">
    <Columns>
        <DxTreeListDataColumn FieldName="Name" Caption="Task" />
        <DxTreeListDataColumn FieldName="EmployeeName" />
        <DxTreeListDataColumn FieldName="StartDate" />
        <DxTreeListDataColumn FieldName="DueDate" />
    </Columns>
</DxTreeList>

<p></p>
Start Row's Visible Index: @StartRowIndex
<p></p>

@code {
    List<EmployeeTask> TreeListData { get; set; }
    ITreeList MyTreeList { get; set; }
    int StartRowIndex = 0;

    protected override void OnInitialized() {
        TreeListData = EmployeeTaskService.GenerateData();
    }
    void TreeList_PageIndexChanged() {
        StartRowIndex = MyTreeList.GetStartRowVisibleIndex();
    }
}

DevExpress Blazor TreeList - Paging

See Also