View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
michael.beckinsale michael.beckinsale is offline
external usenet poster
 
Posts: 274
Default Font colour of specific xl treeview nodes - solved

Hi all,

Further to my earlier posting and in case anybody else wants to do
this in future the following code snippets will colour the font of the
nodes.

Whilst building the treeview:

Dim nodx As Object
Set nodx = TreeView1.Nodes.Add [relative] [relationship] [key] [text]
nodx.Forecolor = vbRed

When node is selected:

TreeView1.SelectedItem.ForeColor = vbRed

Hope this helps somebody, it has caused me lots of frustration, and
now it seems so simple!

Regards

Michael