This is a migrated thread and some comments may be shown as answers.

Is there a known solution for filtering with TreeView?

3 Answers 152 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
salisbury
Top achievements
Rank 1
salisbury asked on 09 Nov 2018, 05:22 PM
I've noticed this has been requested feature in the past, but am wondering if there's a workaround presently available?  A filtering feature like using a text box to only display parents and nodes which contain the text entered.

3 Answers, 1 is accepted

Sort by
0
Dimiter Topalov
Telerik team
answered on 12 Nov 2018, 07:26 AM
Hello,

There is no built-in functionality for filtering the TreeView data as this boils down to processing the data manually based on some filter value (provided in an outside textbox), but you can check out the following documentation how-to article that demonstrates how to achieve the desired functionality:

https://www.telerik.com/kendo-angular-ui-develop/components/treeview/how-to/filtering/

I hope this helps.

Regards,
Dimiter Topalov
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
0
salisbury
Top achievements
Rank 1
answered on 15 Nov 2018, 04:06 PM
is there a expandall function available, so that once a tree is filtered, all of the nodes will expand?
0
Dimiter Topalov
Telerik team
answered on 19 Nov 2018, 08:21 AM
Hi,

There is no built-in expand/collapse all functionality, but we could use the ExpandDirective as demonstrated in the following article from our documentation:

https://www.telerik.com/kendo-angular-ui/components/treeview/expand-state/

Check out the following example that demonstrates how to expand and collapse all nodes programmatically:

https://plnkr.co/edit/I9SoXPANGR8Eq9Ra8Ens?p=preview

I hope this helps.

Regards,
Dimiter Topalov
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
General Discussions
Asked by
salisbury
Top achievements
Rank 1
Answers by
Dimiter Topalov
Telerik team
salisbury
Top achievements
Rank 1
Share this question
or