SpeakComputers.com
Home
Software
Electronics
Desktop Computers
Laptops
Games
Handheld Devices
Mobile Phones
Cameras
Camcorders
Printers
Books
Software Downloads 2012 Software Mac Software Security Student Editions Windows 7 Office 2010
ASP.NET C# VB.NET C++ .NET Infragistics DevComponents

VB.NET TreeView Control.

The VB.NET Windows TreeView control is used to display a hierarchical collection or list of items. An example is commonly seen with Windows explorer.

Namespace: System::Windows::Forms
System.Windows.Forms (in system.windows.forms.dll)

Creating an new VB.NET Windows forms TreeView.
Dim treeview As New TreeView

Creating the first TreeNode for the TreeView.
Dim treenode As New TreeNode
treenode.Text = "Computers"

Adding the first TreeNode to the TreeView control.
treeview.Nodes.Add(treenode)

Creating TreeNode sub items to add to the first TreeNode.
Dim treenode2 As New TreeNode
treenode2.Text = "DELL"

Dim treenode3 As New TreeNode
treenode3.Text = "HP"

Dim treenode4 As New TreeNode
treenode4.Text = "SONY"

Adding the TreeNode sub items to the first TreeNode.
treenode.Nodes.AddRange(New TreeNode() {treenode2, treenode3, treenode4})

Adding the TreeView Control to the Form.
Me.Controls.Add(treeview)

Setting the selected TreeNode.
treeview.HideSelection = False
treeview.SelectedNode = treeview.Nodes(0).Nodes(1)

VB.NET TreeView control Tutorial.
Computer Security
AntiVirus Software
Internet Security
Parental Controls
Backup & Recovery
Computer Protection
Anti Malware
Photo & Video
Photo & Video Editing
Video Music
Desktop Publishing
Professional Design
Home Publishing
Clipart
Business & Accounting
Accounting
Payroll
Check Printing
TAX
H&R Block
Microsoft Office
Design
Graphic Design
Home Design
Garden Design
Interior Design
Computer Aided Design
3D Design
Students & Teacher
Adobe
Microsoft Office
Dragon Naturally Speaking
Corel Draw
Serif
Student/Teacher Software
Copy Right 2006 SpeakComputers.com - All Rights Reserved.
Home About Privacy Policy Resouces