Hello Mladen,
Thank you for the code snippets. Based on them I created a small example that you can use as a reference for achieving the desired result. Basically, the bring into view method doesn't work because the TextSearch.TextPath attached property is not set on the treeview control. The BringPathIntoView() is using TextSearch.TextPath to search in the treeview's items. For example, in your implementation the path is constructed with the Name properties of the business objects. To make the bring path into view to work you should set the TextSearch.TextPath to "Name". Another example - if you have a property defined in the items' view model called PathFragment and you use it to create the path you will need to set the TextPath property to "PathFragment". You can also take a look a the BringIntoView Support help article to see a sample use of the method in a data binding scenario.
Please try this and let me know if it works in your case.
Regards,
Martin
Telerik
Thank you for the code snippets. Based on them I created a small example that you can use as a reference for achieving the desired result. Basically, the bring into view method doesn't work because the TextSearch.TextPath attached property is not set on the treeview control. The BringPathIntoView() is using TextSearch.TextPath to search in the treeview's items. For example, in your implementation the path is constructed with the Name properties of the business objects. To make the bring path into view to work you should set the TextSearch.TextPath to "Name". Another example - if you have a property defined in the items' view model called PathFragment and you use it to create the path you will need to set the TextPath property to "PathFragment". You can also take a look a the BringIntoView Support help article to see a sample use of the method in a data binding scenario.
<telerik:RadTreeView TextSearch.TextPath="Name" />Please try this and let me know if it works in your case.
Regards,
Martin
Telerik
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Feedback Portal
and vote to affect the priority of the items