Click here to Skip to main content
11,923,948 members (58,706 online)
Click here to Skip to main content
Add your own
alternative version


46 bookmarked

Multi-select Treeview control v2.0

, 15 Aug 2004
Rate this:
Please Sign up or sign in to vote.
Multi-select Treeview control v2.0



This is a multi select TreeView Control for the .NET framework. It is possible to select TreeNodes in multiple ways with or without constraints.


The MWTreeView has a few ways of mouse-selecting the TreeNodes by painting anything from a rubberband to very graphical representations. There is even the possibility, using GDI+, to customize the mouse-selection. It is also possible to have TreeNodes of various colors within the same MWTreeView with multi-selection still working. The MWTreeView has a massive amount of configurable settings so that anyone should be able to tailor it to their needs.

Note that when selecting TreeNodes in code the SelectNode (DeselectNode also exists) method should be used. Note that when changing the colors of a TreeNode the ChangeColors method should be used. Do not just change the colors of a TreeNode.

Note that in order to iterate through the selected TreeNodes the following method has to be used (selected TreeNodes are stored in a Hashtable):

foreach(MWTreeNodeWrapper mwtnw in mwtvMWTreeView.SelNodes.Values)
   MessageBox.Show("The " + mwtnw.Node.Text + 
    " TreeNode is selected.");

Contacting me

I can be reached through the forum here at CodeProject or through one of my addresses:

  • My mik address can be found on
  • My mick address can be found on
  • My mikwib address can be found on


This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


About the Author

Mikael Wiberg
Web Developer
Sweden Sweden
No Biography provided

You may also be interested in...

Comments and Discussions

GeneralNodes.Clear Doesn't Clear SelNodes Pin
Christopher Theunissen20-Apr-07 2:16
memberChristopher Theunissen20-Apr-07 2:16 
GeneralRe: Nodes.Clear Doesn't Clear SelNodes Pin
Mikael Wiberg20-Apr-07 7:07
memberMikael Wiberg20-Apr-07 7:07 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web03 | 2.8.151125.3 | Last Updated 16 Aug 2004
Article Copyright 2004 by Mikael Wiberg
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid