This is a migrated thread and some comments may be shown as answers.

Declarative Heirarchy defintion

5 Answers 80 Views
GridView
This is a migrated thread and some comments may be shown as answers.
JTango
Top achievements
Rank 1
JTango asked on 30 Nov 2008, 01:39 AM
Hi guys,

Are there plans to allow parent/child grid hierarchies to be declared declaratively in XAML in future releases of the DataGrid? If not, this is definitely a feature I would like to request. I would make the construction of child grids much simpler and easier to implement.

Cheers

Justin

5 Answers, 1 is accepted

Sort by
0
Nedyalko Nikolov
Telerik team
answered on 02 Dec 2008, 05:21 PM
Hello JTango,

This functionality has always been on our TODO list.
This Q we will be making some improvements to the hierarchy feature as a part the of our Silverlight porting effort.
Of course we will make that available both for WPF and Silverlight.

Greetings,
Nedyalko Nikolov
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Dogu
Top achievements
Rank 1
answered on 10 Mar 2009, 03:15 PM
Is there any way to hide a child view's column declaratively or by code ? our is this a plan too ?
0
Vlad
Telerik team
answered on 12 Mar 2009, 04:40 PM
Hello dogu.tumerdem,

You can set AutoGenerateFieldDescriptors to false for desired GridViewTableDefinition and declare columns programmatically:

            RadGridView1.ItemsSource = ExamplesDB.GetEmployees(); 
 
            TableRelation relation = new TableRelation(); 
            relation.FieldNames.Add(new FieldDescriptorNamePair("EmployeeID""EmployeeID")); 
 
            GridViewTableDefinition definition = new GridViewTableDefinition(); 
            definition.AutoGenerateFieldDescriptors = false
 
            GridViewDataColumn column = new GridViewDataColumn(); 
            column.DataMemberBinding = new Binding("OrderID"); 
            column.HeaderText = "Order ID"
            column.IsFilterable = false
            definition.FieldDescriptors.Add(column); 
 
            column = new GridViewDataColumn(); 
            column.DataMemberBinding = new Binding("OrderDate"); 
            column.DataFormatString = "{0:d}"
            column.HeaderText = "Order Date"
            column.IsFilterable = false
            definition.FieldDescriptors.Add(column); 
 
            definition.DataSource = ExamplesDB.GetOrders(); 
            definition.Relation = relation; 

All the best,
Vlad
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Selvam
Top achievements
Rank 1
answered on 30 Apr 2009, 07:07 PM
Do you guys have any updates on this feature? I think you had plan to build something for this by Q1...

I too need this feature badly. I'm trying to follow 100% declarative code for View definition in my project. I got stuck on defining Hierarchial grid using XAML and I don't know whether RadGridView supports this or not?

Please provide more information on how to define custom column header with Combo Box, Check Box... on the child grid in hierarchy.


0
Pavel Pavlov
Telerik team
answered on 05 May 2009, 09:01 AM
Hi Selvam,

Refactoring the hierarchy is a big and heavy task and unfortunately we have still some work to do. As you mention it is critical for you to declaratively define hierarchy children settings I would recommend to try the approach stated here. Basically it is a hack to prevent the child grid in hierarchy to automatically build columns and settings and respect the XAML settings. Please have a look at the example in my  post there. Meanwhile we are doing our best to push the improved hierarchy logic to a shippable state.


Best wishes,
Pavel Pavlov
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
GridView
Asked by
JTango
Top achievements
Rank 1
Answers by
Nedyalko Nikolov
Telerik team
Dogu
Top achievements
Rank 1
Vlad
Telerik team
Selvam
Top achievements
Rank 1
Pavel Pavlov
Telerik team
Share this question
or