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

How to use aggregate on nested members

1 Answer 99 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Katie
Top achievements
Rank 1
Katie asked on 05 Jan 2012, 07:43 PM
Hi, 

I am using telerik rad gridview to display customers. My customer object have another class as a property. 

So the object looks like: 

public class Product
{
public int ProductID {get; set;}
public decimal Amount {get; set;}
public string ProductName {get; set;}
}
 
public class Customer
{
public int CustomerID {get; set;}
public Product CurrentProduct {get; set;}
public string FirstName {get; set;}
public string LastName {get; set;}
}
 
Now I binding a list of customers to the grid and displaying Product Info too. But how do I do an aggregate function? Normally I would put Amount as the source field for the function.

1 Answer, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 06 Jan 2012, 11:09 AM
Hello,

 You could try to create your own custom aggregate function. Please refer to the custom aggregates example in the wpf demos or to this online example.  

All the best,
Didie
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
GridView
Asked by
Katie
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Share this question
or