ASP.NET 3.5 and above only

ASP.NET TreeView - Types of Node Selection Mode

When the SelectMode property is set to,
  • Select, this will select the node when you click the node text.
  • Expand, this will expand the child nodes instead of node selection when you click the node text.
Select Expand
  • Node 0
    • Node 00
      • Node 000
  • Node 1
    • Node 10
      • Node 100
  • Node 0
    • Node 00
      • Node 000
  • Node 1
    • Node 10
      • Node 100
[ASPX]

<obout:Tree ID="OboutTree1" CssClass="vista" Width="150px" runat="server">
    <Nodes>
        <obout:Node Text="Node 0">
                     <obout:Node Text="Node 00">
                    ...
                    </obout:Node>
        ...
        </obout:Node>
        ...
    </Nodes>
</obout:Tree>


<obout:Tree ID="OboutTree2" CssClass="vista" Width="150px" runat="server">
    <Nodes>
        <obout:Node SelectMode="Expand" Text="Node 0">
            <obout:Node SelectMode="Expand" Text="Node 00">
                ...
            </obout:Node>
        ...
        </obout:Node>
        ...
    </Nodes>
</obout:Tree>
            

"Once again, thanks for the quick reply and for a great product."

Magnus Larewall
SYSteam DTS AB

Random testimonial   All testimonials