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

How can i get nodeChecked.value when node click

2 Answers 52 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Patrick0103
Top achievements
Rank 1
Patrick0103 asked on 21 Jan 2009, 02:37 PM
Hi there,

I have a problem. when click the node then i can check to occur the event  'OnNodeClick'.
However, i cann't get all of data like node's value or text.
Exactly, that clicked node has some data.
How can i fix this problem?

Below is code :

aspx page :
<rad:RadTreeView ID="radTree" runat="server" AutoPostBack="True" OnNodeClick="radTreeNodeClick"></rad:RadTreeView>

of course, data binding is completed programmatically.

ascx page :
protected void radTreeNodeClick(object sender, RadTreeNodeEventArgs e)
    {
        this.sid = Convert.ToInt32(e.NodeChecked.Text);
        this.ListPage();
    }

Many thanks.

2 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 21 Jan 2009, 04:18 PM
Hello Patrick0103,

Unfortunately I couldn't understand what the problem is. Could you please elaborate? The clicked node should be accessible via the e.NodeClicked property. All of the properties should be available as well.

Kind regards,
Albert
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Patrick0103
Top achievements
Rank 1
answered on 22 Jan 2009, 12:21 AM
Oh~ i'm so sorry.I figure it out.
It is the reason of postback.

thanks for your interesting.
patrick.
Tags
TreeView
Asked by
Patrick0103
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Patrick0103
Top achievements
Rank 1
Share this question
or