Results 1 to 4 of 4

Thread: [2008] ASP.NET VB - TreeView Node And SQL

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jan 2006
    Posts
    111

    Question [2008] ASP.NET VB - TreeView Node And SQL

    Hi All,

    I have successfully followed a article which shows how to populate a treeview using SQL as the datasource.

    What I would like to do is then only a person's name is clicked, their information is displayed using SQL as the datasource.

    The TreeView has been setup in the following structure

    -Company Name
    |
    |_ Accounting
    | |
    | |_John
    | |_Mary
    |
    |_Marketing
    |
    |_David
    |_Joan

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: [2008] ASP.NET VB - TreeView Node And SQL

    Are you looking to handle an event in which the node is clicked? Why not set the NavigateUrl property for the treeview nodes when populating them?

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Jan 2006
    Posts
    111

    Question Re: [2008] ASP.NET VB - TreeView Node And SQL

    Hi mendhak,

    On NodeSelect Handle would be the way to go. How would I apply the NavigateURL only to the nodes with a name?

  4. #4
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: [2008] ASP.NET VB - TreeView Node And SQL

    I see that the Treeview has a DataBound event that you can use. Use it to access your nodes and set the NavigateUrl property.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width