Change color and font of CTreeCtrl item.

Please let me know if there is a way to change color and font of CTreeCtrl item. Tree control is pu on the view (not in dialog).

The similar qiestion is how to make tree control item disabled.

Thanks in advance

Sergei
sergtrAsked:
Who is Participating?
 
KurtVonConnect With a Mentor Commented:
What doesn't work?  Post the code you wrote and maybe it can be figured out.
0
 
AndyAinscowFreelance programmer / ConsultantCommented:
A tree control has functions SetTextColor and SetBkColor.  Are they not suitable?
0
 
KurtVonCommented:
If the built in functions don't offer enough control, perhaps something more like this: http://www.codeproject.com/treectrl/colortreectrl.asp would work?

Hope this helps.
0
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

 
sergtrAuthor Commented:
SetTextColor and SetBkColor methods are related to whole CTreeCtrl but the question is regarding to certain item...
http://www.codeproject.com/treectrl/colortreectrl.asp  is example, which doesn't work in a view properly.

Thanks,

Sergei
0
 
KurtVonCommented:
Create a CCtrlView and put the alternative tree control on that.
0
 
sergtrAuthor Commented:
It's exactly that has been done... unfortuantely it doesn't work properly...

Thanks,
Sergei
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.