473,505 Members | 13,696 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

get the selected node name

I have a treeview in my ASP.NET vb.net application.when someone selects a
node
on the treeview How do I set the node name
myNodeName = TreeView1.Nodes(TreeView1.SelectedNodeIndex).Text
The above code only gave me the value of the parent Node
Any and all help would be greatly appreciated!!!!
--
ONil@.
MX.
Nov 18 '05 #1
2 5902
me.TreeView.GetNodeFromIndex(Me.Treeview.SelectedI ndex).text = "some value"

"ONIL@" <on***@hotmail.com> wrote in message
news:uP**************@tk2msftngp13.phx.gbl...
I have a treeview in my ASP.NET vb.net application.when someone selects a
node
on the treeview How do I set the node name
myNodeName = TreeView1.Nodes(TreeView1.SelectedNodeIndex).Text
The above code only gave me the value of the parent Node
Any and all help would be greatly appreciated!!!!
--
ONil@.
MX.

Nov 18 '05 #2

Hi Rick..!
Thanks.
with a few changes it works..
look
TreeView.GetNodeFromIndex(TreeView.SelectedNodeInd ex.ToString).Text

And in this way I can get the text of the user selected node.

Best Regards.

--
ONil@.
MX.

"rickpayne" <rp****@NOSPAMdigitalbang.com> wrote in message
news:e1**************@tk2msftngp13.phx.gbl...
me.TreeView.GetNodeFromIndex(Me.Treeview.SelectedI ndex).text = "some value"
"ONIL@" <on***@hotmail.com> wrote in message
news:uP**************@tk2msftngp13.phx.gbl...
I have a treeview in my ASP.NET vb.net application.when someone selects a node
on the treeview How do I set the node name
myNodeName = TreeView1.Nodes(TreeView1.SelectedNodeIndex).Text
The above code only gave me the value of the parent Node
Any and all help would be greatly appreciated!!!!
--
ONil@.
MX.


Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
1602
by: ai2003lian | last post by:
Assuming I have the following two xml file: source.xml: <AllFields> <Group name="G1"> <Field fieldName="f1">Value1</Field> <Field fieldName="f2">Value2</Field> <Field...
2
2118
by: worzel | last post by:
Can't suss this out for the life of me, googling of no help either. Okay, new to win forms; I have a treeview with several root nodes, each having a single level of child nodes underneath. I also...
2
3472
by: probashi | last post by:
Hi, >From the sample xml, I am trying to select a book and then select the author of the select book. In the example code first SelectSingleNode selects a book. Second SelectSingleNode on the...
1
1356
by: Chris Ashley | last post by:
I'm trying to use a treeview control for navigation in an app. How do I determine which node has been selected? I can't use the text property because some nodes have the same name, and the index...
1
7476
by: Wes | last post by:
Hi there, Does anyone know how to get the selected node from a ASP.Net 2.0 TreeView in Javascript? I used to be able to get it in the old webcontrols one, but now the properties have changed...
2
2408
by: rfm | last post by:
I have a TreeView with 1 expanded top node, it has several childnodes (call it row A), which have childs of their own. The top node is selected correctly and all childnodes from the row A nodes...
0
3274
by: divya1949 | last post by:
Create a windows c# application which will Read a xml file and populate nodes in the treeview. 1 On selection of treenode display the child nodes of that node in listview control 2. ...
1
3924
by: =?Utf-8?B?Rmx5Z3V5?= | last post by:
I have a TreeView with so many nodes that it requires scroll bars. When the user selects a node the screen is refreshed and the selected node is no longer visible. The TreeView is opened to the...
0
1538
by: Dave Mathew | last post by:
I'm in the process of building some navigation for a website. I would like to use the capabilities of the sitemap in asp.net but have ran into some styling/usability issues in the past using just...
0
7213
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7366
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7017
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7471
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5610
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4698
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3187
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3176
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1526
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.