如何创建三态复选框,在.NET中的TreeView控件? [英] How do I create tri-state checkboxes with a TreeView control in .NET?
问题描述
我在Windows TreeView控件窗体项目已经复选框打开。由于TreeView控件有嵌套的节点,我需要的复选框,以便能够有某种三模式选择。我无法找到一个方法来做到这一点(我只能有复选框全部选中或取消选中)。
I have a treeview control in a Windows Forms project that has checkboxes turned on. Because the treeview control has nested nodes, I need the checkboxes to be able to have some sort of tri-mode selection. I can't find a way to do this (I can only have the checkboxes fully checked or unchecked).
推荐答案
如果你在谈论Windows窗体,这篇文章应该帮助你建立你的三态的TreeView:
If you are talking about Windows Forms, this article should help you build you tri-state TreeView:
HTTP://www.$c$cproject。 COM / KB /树/ treeviewex2003.aspx?显示=打印
如果您需要关于asp.net我认为你需要使用一个第三方组件一个TreeView三态复选框。来看看一个这个,然后点击三态复选框左侧的:
If you need tri-state checkboxes on a treeview on asp.net i think you need to use a third-party component. Take a look a this one, and click "tri-state checkboxes" on the left side:
http://www.aspnetexpert.com/demos/tree/default.aspx
这篇关于如何创建三态复选框,在.NET中的TreeView控件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!