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

TreeView in ComboBox

1 Answer 55 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Yoly
Top achievements
Rank 2
Yoly asked on 09 Dec 2008, 06:12 PM
Hi,

I created a page with a treeview inside a combobox like your Treeview in Combobox example.
http://demos.telerik.com/aspnet-ajax/Treeview/Examples/Functionality/TreeViewComboBox/DefaultCS.aspx

I followed the example and it worked perfectly.  However, I need to set an initial value for the combo/treeview with values from the database.  I assumed I had to :
1) select the corresponding item in the treeview
2) set the text and the value for the radcombo.

I haven't been able to implement this successfully.  I selected the item in the treeview with no problems, and also have been able to set the radcombobox text, but for some reason cannot set the value, and I need this value in order to insert it in a database.

This is what I've been trying to do:

   Dim selectedNode As Telerik.Web.UI.RadTreeNode = tvParentPage.FindNodeByValue(parentPageId)

                Me.ParentId.Items(0).Value = parentPageId
                Me.ParentId.Items(0).Text = selectedNode.Text
                Me.ParentId.Text = selectedNode.Text

Any sugestions on what's missing?

Thank you.
YCeron

1 Answer, 1 is accepted

Sort by
0
Veselin Vasilev
Telerik team
answered on 12 Dec 2008, 03:25 PM
Hello yceron,

I am afraid I cannot advice you until I see your implementation.
Can you please open a support ticket and attach a sample project there.

Best wishes,
Veselin Vasilev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
ComboBox
Asked by
Yoly
Top achievements
Rank 2
Answers by
Veselin Vasilev
Telerik team
Share this question
or