views:

258

answers:

2

Hello,

I have a question regarding the ASP.NET 3.5 Treeview and Treenodes. I'd like to build a Treeivew that supports multistate checkbox. I actually would like 4 states - checked, unchecked, indeterminate (like a tri-state box - parent is tri-state, if not all of the children are checked) and NotAppicable (this checkbox would be an X and greyed out). I've read up on how to add custom user controls, by using a Web User Control (.ascx), but it doesn't seem to work that way for overriding the TreeNode and TreeView. I am showing static data in an .xml file, and I really like the capability of binding the treeview to a datasource. So, I'd prefer to continue using the tree if I can.

So I guess I have a few questions:

  1. How do I override the treeview or treenode, and add it to a webform? (So I can still use the designer?) Do I have to build them into a .dll and load that way? Or can I add .cs files to my project?

  2. Does anyone have any ideas on how to change the treeNode to handle checkstates?

  3. Any ideas on how to use my custom images for the different check states?

Thanks!

A: 
AE
A: 

Thanks a lot... it worked for me...

Pankaj Bajpai