DxTreeView.GetCheckedNodeInfo() Method
Returns a collection of currently checked nodes.
Namespace: DevExpress.Blazor
Assembly: DevExpress.Blazor.v24.1.dll
NuGet Package: DevExpress.Blazor
Declaration
public IEnumerable<ITreeViewNodeInfo> GetCheckedNodeInfo()
Returns
Type | Description |
---|---|
IEnumerable<ITreeViewNodeInfo> | Checked nodes. |
Remarks
The following code snippet gets a collection of checked nodes and displays size of this collection:
Number of checked nodes: @CheckedCount
<DxTreeView @ref="MyTreeView"
Data="@Data"
CheckMode="TreeViewCheckMode.Recursive">
<DataMappings>
<DxTreeViewDataMapping Text="Name"
Key="Id"
ParentKey="CategoryId" />
</DataMappings>
</DxTreeView>
<DxButton Text="Count Checked Nodes" Click="GetCheckedNodes" />
@code {
DxTreeView MyTreeView;
int? CheckedCount;
void GetCheckedNodes() {
CheckedCount = MyTreeView.GetCheckedNodeInfo().Count();
}
}
See Also