views:

79

answers:

1

I need to be able to display and edit a hierarchical list of tasks in a C# app. It can either be a Windows form app, or ASP.NET.

Basically, I want similar behaviour to the way Microsoft Project handles tasks.

The control would need to:

1) Maintain a list of items made up of several fields

2) Each item can have a number of children (at least 3 levels of nesting)

3) It needs to be very easy to change the parents/children of an item

4) It needs to be very easy to edit the fields (as fast as changing cells in Excel)

5) It needs to be very easy to reorder the items by dragging and dropping or cut and paste

6) If I can easily connect the control to a database, even better

Anyone got any recommendations for controls for me to look at?

+3  A: 

Hierarchical data structures (trees) are visualized with treeview controls. There are built-in treeviews in ASP.NET and WinForms but given that you are looking for features such as editing and drag & drop, you might consider a commercial product. Commercial products will make the job of adding these features easier than using built-in controls.

A favourite of mine are the Telerik controls. They sell WinForms, ASP.NET (and Silverlight) versions of treeviews.

Telerik grids (RadGrid) also supports nesting of rows. If your hierarchical data has a known and limited depth and, especially, a meaning to each level of depth, then using the nested rows of a RadGrid (or similar product from another vendor) would work well too.

Canoehead
I think what I need is more like a hierarchical grid view rather than a tree view, but the only ones I've found have limited hierarchical features. The Telerik Grid control looks interesting thoguh so I'm going to check that out. Thanks.
Mendokusai
The Telerik Grid (at least for ASP.NET but maybe for WinForms too) supports nesting of rows. I've used it in the past to display a table of customers with their orders nested underneath. Quite easy to use too.
Canoehead
I've edited my answer to add the use of grids that support nested rows.
Canoehead