Solved building Organizational Hierarchy in TreeView with Department selection

Posted on 2012-09-05
Last Modified: 2012-09-07

I store the hierarchical organizational data for a company in a table shown in the image below.
I use a recursive method to add the nodes based on the "node address" column.
I need to add in functionality to exclude certain departments. This will interfere with my code in general and make my build disjointed. Can anyone suggest a better way to do this. Thanks

Question by:murbro
    LVL 25

    Assisted Solution

    by:Shaun Kline
    Are the departments you need to exclude at the lowest level of the heirarchy or part of a branch in the tree, consider excluding them when you retrieve your data.
    LVL 96

    Accepted Solution

    ASP.NET has a way to bind the TreeView to a data source that supports hierarchical data.

    Binding to Hierarchical Data

    Author Closing Comment

    Thank you both for the help

    Featured Post

    What Security Threats Are You Missing?

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Join & Write a Comment

    Suggested Solutions

    Introduction This article shows how to use the open source plupload control to upload multiple images. The images are resized on the client side before uploading and the upload is done in chunks. Background I had to provide a way for user…
    Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
    This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now