VB.Net Get TreeView Node Text And Name

How To Get Selected Node Text And Name From TreeView Using Visual Basic .Net

Get TreeView Node Text / Name Using VB.Net

In this VB.NET Tutorial we will see How To Get The Selected TreeView Node Name Or Text And Display The Values Into A TextBox On treeView AfterSelect Event In Visual Basic.Net Programming Language And Visual  Studio Editor.




Project Source Code:


Public Class Get_TreeView_Node_Text_Name

    Private Sub TreeView1_AfterSelect(sender As Object, e As TreeViewEventArgs) Handles TreeView1.AfterSelect

        ' get node text
        TextBox1.Text = TreeView1.SelectedNode.Text

        ' get node name
        TextBox1.Text = TreeView1.SelectedNode.Name

    End Sub
End Class


OutPut:

Get Selected TreeView Node Text And Name In VB.Net




Share this

Related Posts

Previous
Next Post »