Turn off Link on Parent Node in asp:TreeView control

Hi All,

I've built a treeview control, programmatically adding the nodes in the code behind, all is fantastic, however my Parent Nodes are showing as hyperlinks (blue with the pointer cursor) this is fine for the children as they are links, but the parents aren't, I've set no NavigateUrl or Value, they are just category headings if you will.

Is there a way I can stop them being hyperlinks? If you click them they just do a postback, that's not what I want at all!!

Thanks and Regards
wooderzAsked:
Who is Participating?
 
wooderzConnect With a Mentor Author Commented:
No need to worry, I changed the SelectAction to Expand and now this behaviour will do nicely. Thanks
0
All Courses

From novice to tech pro — start learning today.