Skip to main content
All docs
V25.1
  • .NET 8.0+
    • The page you are viewing does not exist in the .NET Framework 4.6.2+ platform documentation. This link will take you to the parent topic of the current section.

    BlazorControlViewItem Class

    A container for custom ASP.NET Core Blazor components displayed in a Detail View.

    Namespace: DevExpress.ExpressApp.Blazor.Editors

    Assembly: DevExpress.ExpressApp.Blazor.v25.1.dll

    NuGet Package: DevExpress.ExpressApp.Blazor

    Declaration

    public class BlazorControlViewItem :
        ControlViewItem

    Remarks

    The following code snippet uses BlazorControlViewItem to create a custom component:

    File: CS\MainDemo.Blazor.Server\Editors\ButtonComponent.razor

    @using DevExpress.Blazor
    @using DevExpress.ExpressApp
    @using DevExpress.ExpressApp.Blazor.Editors
    
    <DxButton Text="Click me!" Click=@ClickFromUI />
    
    @code {
        [CascadingParameter] public BlazorControlViewItem ViewItem { get; set; }
    
        void ClickFromUI() {
            ViewItem.Application.ShowViewStrategy.ShowMessage("Action is executed!");
        }
    }
    

    When you add the custom component to a Detail View, specify the component type as the ControlTypeName property value in the Model Editor:

    XAF Add A Control Detail Item in the Model Editor, DevExpress

    For more information about custom ASP.NET Core Blazor View Items, refer to the following topics:

    Implements

    Inheritance

    Object
    ViewItem
    ControlViewItem
    BlazorControlViewItem
    See Also