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

GetItemByPath sub nodes

2 Answers 27 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Darren Stoppler
Top achievements
Rank 1
Darren Stoppler asked on 27 May 2010, 02:01 PM
The GetItemByPath only seems to work to one level.  I'm programatically loading the control (no binding involved) after the tree view loaded event has fired.

Each item added is set with IsExpanded  = true.  I have the following showing in my tree view:-

Car
   Car A
Bike
   Bike A
   Bike B

GetItemByPath will find "Car" but it returns a null object if I search for "Car A".

This is driving me crazy.  Is there anyway of getting this to work?

Thank you.

2 Answers, 1 is accepted

Sort by
0
Accepted
Viktor Tsvetkov
Telerik team
answered on 01 Jun 2010, 11:46 AM
Hi Darren Stoppler,

In your case to get the item "Car A" you have to use the full path "Car\\Car A". You can use a different separator instead of "\\" as it is described here.

Greetings,
Viktor Tsvetkov
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Darren Stoppler
Top achievements
Rank 1
answered on 01 Jun 2010, 01:20 PM
Thanks Viktor, that worked fine.
Tags
TreeView
Asked by
Darren Stoppler
Top achievements
Rank 1
Answers by
Viktor Tsvetkov
Telerik team
Darren Stoppler
Top achievements
Rank 1
Share this question
or