How to: Work with Tree View control

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
6,963
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on May 18, 2010

a quick how to showing how easy to create a tree using treeview control in vb. Check out the web site:

http://www.mka-soft.com

there you can find more tutorials and how to.

Category:

Education

Tags:

License:

Standard YouTube License

  • likes, 1 dislikes

Link to this comment:

Share to:

Uploader Comments (mkaatr)

  • Dim myNode As Windows.Forms.TreeNode yields an error message type Type 'windows,Form, treenode' is not defined. What does this mean?

  • @ddsharper

    Hi there... long time no see. Hope you are doing fine. This error means that the compiler can't identify what this data type/class consist of and how to create it. This is kind of strange, since the Windows.Forms.TreeNode class is already provided for you to use. Can you give more details about it? For example, are you using this in a Module? a Class? and what is the Project Type you are using? is it a Class Library? Console App? or something else?

    yours.

  • @mkaatr the red i box said to change it from 'windows,Form, treenode' to 'treenode' and when i did the error went away!! what do you think?

  • @ddsharper

    Hi there...

    The reason for the error is that there is some kind of conflict in the naming. VB.NET uses the name space to distinguish between different libraries that have the same name. For example you can have :

    Module1.Test()

    Module2.Test()

    and you can still call any one of these even though they have the same name(Test).

    As for the error itself. I think if we use "System.Windows.Forms.TreeNode­" it will be more correct and the error will be gone as well.

    yours

  • What code would you use to keep the tree expanded at all times? Would you add code to the form load property? Thank you.

  • @ddsharper

    Hi there...

    whenever you want to expand all the nodes, just call expandall.  TreeView1.ExpandAll()

    you can call this method after filling the tree in the form load event to make sure that the tree nodes appear expanded.

see all

All Comments (10)

Sign In or Sign Up now to post a comment!
  • for fuck sake im so tired of find VB tuts. VB is outdated and is the nigger cereal brand programming language. Fuck this, and fuck you.

  • @mkaatr Hi! Well it's a part of the code you wrote with the document navigator but once I moved it into my program the error showed up in that code.

  • @mkaatr thanks so much. your teaching methods are incredible.

Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more