TreeListView ItemAdapter

Grids for WPF Forum

The latest build of this product (v24.1.5) was released 1 month ago, which was before this thread was created.
Posted 16 days ago by yejianbiao
Version: 24.1.5
Avatar

Hi,

I set up TreeListBoxItemAdapter ChildrenQueryModeDefault = OnExpansion, then by rewriting CanHaveChildren can control node, when I have modified the data of the current node, I want to reset whether the node can be expanded or not, but canhavechildren will not be executed again.Is there a way to control whether the node can be expanded at any time.

Comments (3)

Posted 16 days ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hello,

If you call the TreeListBox.InvalidateChildren(item) method and pass it your view model item, it should requery the CanHaveChildren state.


Actipro Software Support

Posted 15 days ago by yejianbiao
Avatar

Is there any other solution? My current approach is not convenient to get treelistbox in the place of business logic. I have tried to bind isexpandable, but it will cause other problems.

Posted 15 days ago by Actipro Software Support - Cleveland, OH, USA
Avatar

If your view model raises an INotifyPropertyChanged.PropertyChanged event for the property name that is set via the item adapter's ChildrenPath, our logic that watches the view model will think the items changed and should requery the CanHaveChildren state.


Actipro Software Support

Add Comment

Please log in to a validated account to post comments.