TabReorderEventArgs.ToIndex Property
Returns the index (according to the component markup) of the end tab position.
Namespace: DevExpress.Blazor
Assembly: DevExpress.Blazor.v24.2.dll
NuGet Package: DevExpress.Blazor
Declaration
public int ToIndex { get; }
Property Value
Type | Description |
---|---|
Int32 | The tab index according to the component markup. |
Remarks
Use FromIndex and ToIndex
properties to get information about start and end tab positions among other tabs.
The following example restricts the last tab from being moved from its position.
<DxTabs AllowTabReorder="true" TabReordering="@TabReordering">
<DxTab Text="The 1st Tab" />
<DxTab Text="The 2nd Tab" />
<DxTab Text="The 3rd Tab" />
<DxTab Text="The 4th Tab" />
<DxTab Text="The Last Tab" />
</DxTabs>
@code {
void TabReordering(TabReorderEventArgs e) {
if ((e.FromIndex == 4) || (e.ToIndex == 4)) {
e.Cancel = true;
}
}
}
See Also