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

ITabInfo Interface

Contains information about a tab.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

#Declaration

C#
public interface ITabInfo

#Remarks

Use interface properties to obtain information about the processed tab.

razor
<DxTabs TabClosing="TabClosing">
    @foreach (var employee in Employees) {
        <DxTabPage Text="@(employee.FirstName + ' ' + employee.LastName)" AllowClose="true" >
            ...
        </DxTabPage>
    }
</DxTabs>

@code {
    void TabClosing(TabCloseEventArgs args) {
        // Prevent disabled tabs from closing 
        // and disable closing tab by pressing the Delete key.
        args.Cancel = !args.TabInfo.Enabled || (args.CloseReason == TabCloseReason.DeletePress);
    }
}
See Also