Results 1 to 4 of 4

Thread: Adding columns to TreeView Nodes

  1. #1

    Thread Starter
    Wait... what? weirddemon's Avatar
    Join Date
    Jan 2009
    Location
    USA
    Posts
    3,826

    Adding columns to TreeView Nodes

    I'd hate to have to create my own control, but will attempt to if it comes to it.

    I need to display columns within a TreeView node so I can display specific information about that item within columns.

    Think of a ListView as a TreeNode. That's basically what I'm trying to get at.

    I'm hoping for a relatively easy solution, but I can't imagine this would be too easy.

    Any information would be helpful.

    Thanks
    CodeBank contributions: Process Manager, Temp File Cleaner

    Quote Originally Posted by SJWhiteley
    "game trainer" is the same as calling the act of robbing a bank "wealth redistribution"....

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Adding columns to TreeView Nodes

    I would strongly suggest that you do as Windows Explorer does and simply use two separate controls: a TreeView and a ListView. When the user selects a node in the tree you display the corresponding data in the ListView. What you're asking for would be rather difficult I think and I can't imagine it presenting a pleasant interface to the user. The TreeView/ListView combo is something that's familiar to every Windows user so that's a good UI design.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Wait... what? weirddemon's Avatar
    Join Date
    Jan 2009
    Location
    USA
    Posts
    3,826

    Re: Adding columns to TreeView Nodes

    That's probably a plausible solution. I've seen many controls like that.

    I wanted the ListView within the Child Node so I could display an item in a Node. Then I would display sub items in child nodes and provide additional information about those subitems in the "ListView."
    CodeBank contributions: Process Manager, Temp File Cleaner

    Quote Originally Posted by SJWhiteley
    "game trainer" is the same as calling the act of robbing a bank "wealth redistribution"....

  4. #4
    Frenzied Member
    Join Date
    May 2006
    Location
    some place in the cloud
    Posts
    1,886

    Re: Adding columns to TreeView Nodes

    Once I use a fixed font in the treeview control to simulate columns

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width