You can try inheritance, that means:
1. you create a class that inherits checkbox and implement your behavior,
let's say a "State" property that will paint the checkbox as you wish
(overriding the paint method).
2. you find how to intercept the creation of a treeNode in the treeView
control and change it's checkBox to yours.
3. check the state of the sub-checked items and set the "State" property for
the checkbox you are assigning to the treeNode
Hope this can help,
Regards,
Victor Reboucas
[quoted text, click to view] <sonali_reddy123@yahoo.com> wrote in message
news:1126879829.552183.253870@f14g2000cwb.googlegroups.com...
> Hi,
>
> I need a help regarding the checkbox property for a treeview.
> Is there any way to change the color (appearance) of the treenode
> which will indicate that the treenode is half way selected.
> I mean I want to change the checkbox apperance only if few
> subitems under a node are selected that means a the checkbox for
> the entire node should nor be checked as some of its subitems are
> not selected.
>
> Can we have some property which will change the appearance of the
> checkbox to some other color so that I can indicate the node to be
> half selected.
>
> Thanks in advance.
>