RadTreeListView - Is it possible to calculate totals instead of setting them at each group level?

2 posts, 0 answers
  1. Rob
    Rob avatar
    238 posts
    Member since:
    Jan 2009

    Posted 04 Jul 2011 Link to this post

    In the example data object used here, is it possible to calculate a nodes "count" (for a particular node that has a non-empty child collection) instead of assigning it?  For example, "drinks.Count" is set to "35".  Are we able to define the columns in such a way that the count is summed instead of set?

    Would it be better ot provide a flat list of data (with some sort of "ParentID" field) instead of a hierarchical one?

  2. Dimitrina
    Dimitrina avatar
    3769 posts

    Posted 07 Jul 2011 Link to this post

    Hi Rob,

     If you would like to use a flat list of data, then it would be better to use a RadGridView. You may then group on an appropriate property and get all the drinks related to it under a grouped row. You may use an aggregate function to count all the rows (nodes) under the grouped row.

    I am not quite sure that I understand your idea about RadTreeListView the right way. May you please explain it in more structured way? What your data structure is and what you would like to get as a result?

    Kind regards,
    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

Back to Top