三个状态树视图窗体 [英] Three State Treeview Windows Forms

查看:150
本文介绍了三个状态树视图窗体的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

标准TreeView的一个缺点是,您无法显示部分选择,表示选择了某些子项。复杂树中的部分选择允许用户容易地确定选择的位置,即使树没有完全展开。类似的想法在manu备份程序中使用,以允许用户选择要备份的文件。



有人知道一种在树视图中进行检查的方法复选框灰色?我想灰色父节点的检查,当它的一些(但不是所有)其子节点被检查。 Kinda就像您在软件安装过程中选择要安装的选项时看到的内容。



我看过几个帖子,但是较旧(2000年,2007年) p>

我现在,在2010年,可能更好的答案是必需的。我使用VS 2008。 Net 3.5,Windows窗体

解决方案

有一个关于代码项目的好文章。 三态树视图控件


One of the frustrations with the standard TreeView is that you can't show a partial selection to indicate that some of the children are selected. A partial selection in a complex tree allows the user to easily determine where the selections are, even if the tree is not completely expanded. A similar idea is used in manu backup programs to allow the user to select the files to be backed up.

Does anyone know of a way to make the checks in a treeview checkbox gray? I want to gray the check of a parent node when some (but not all) of its child nodes are checked. Kinda like what you see when you are selecting options to install during a software installation.

I have seen several post, but is older (2000, 2007 year).

I now, in 2010, the better answer possible is required. I use VS 2008 . Net 3.5 , Windows Forms

解决方案

There's a nice article on code project about just this. Tri-State TreeView Control

这篇关于三个状态树视图窗体的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆