Skip to main content
All docs
V25.1
  • DevExpress v25.1 Update — Your Feedback Matters

    Our What's New in v25.1 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

    DxTreeViewNode.AllowCheck Property

    Specifies whether the TreeView node can be checked.

    Namespace: DevExpress.Blazor

    Assembly: DevExpress.Blazor.v25.1.dll

    NuGet Package: DevExpress.Blazor

    #Declaration

    C#
    [DefaultValue(true)]
    [Parameter]
    public bool AllowCheck { get; set; }

    #Property Value

    Type Default Description
    Boolean true

    true to allow a node check; otherwise, false.

    #Remarks

    Set the CheckMode property to Multiple or Recursive to display checkboxes in nodes. The CheckedChanged event is raised when a user changes a node’s check state.

    Set the AllowCheck property to false to hide a checkbox for the node.

    You can use the CheckBoxReadOnly property to activate read-only mode for the node’s check box.

    Razor
    <DxTreeView CheckMode="TreeViewCheckMode.Multiple">
        <Nodes>
            <DxTreeViewNode Text="Metals">
                <Nodes>
                    <DxTreeViewNode CheckBoxReadOnly="true" Text="Alkali metals"/>
                    <DxTreeViewNode CheckBoxReadOnly="true" Text="Alkaline earth metals" />
                    <DxTreeViewNode Text="Inner transition elements">
                        <Nodes>
                            <DxTreeViewNode Text="Lanthanides"/>
                            <DxTreeViewNode Text="Actinides" />
                        </Nodes>
                    </DxTreeViewNode>
                    <DxTreeViewNode AllowCheck="false" Text="Transition elements" />
                    <DxTreeViewNode AllowCheck="false" Text="Other metals" />
                </Nodes>
            </DxTreeViewNode>
            <DxTreeViewNode Text="Metalloids"/>
            <DxTreeViewNode Text="Nonmetals">
                <Nodes>
                    <DxTreeViewNode Text="Halogens"/>
                    <DxTreeViewNode Text="Noble gases"/>
                    <DxTreeViewNode Text="Other nonmetals"/>
                </Nodes>
            </DxTreeViewNode>
        </Nodes>
    </DxTreeView>
    

    Toast render mode and styles

    See Also