Question on ColumnGroups: is there anyway to build from the datasource?

4 posts, 1 answers
  1. Stargazer
    Stargazer avatar
    73 posts
    Member since:
    Jan 2007

    Posted 25 Nov 2009 Link to this post

    Hello!

    Well, what I'm looking for is a way to take advantage of the ColumnGroups feature of the grid, but doing so in an automated manner. I have a query that returns me a bunch of records. Those records are hierarchical for each person, and represent a tree of grades.

    I used it to populate a radtreeview with ParentIDMember and it works just great! I also use a similar query to get the data to populate a crosstab on a report to print that info and it do work nicely.

    What I would like to achieve is something as the crosstab, where we just have to create the groups and then indicate what is the data source. Everything happens automagically...Little coding is needed on my part.

    In the case os the datagrid, I have to create and populate all the columngroups "by hand", resulting in some big and ugly coding.

    Any suggestions?
  2. Jack
    Admin
    Jack avatar
    2335 posts

    Posted 25 Nov 2009 Link to this post

    Hello Stargazer,

    That's interesting. Could you please specify in detail the result and the data. Currently RadGridView can't build its column groups automatically. However, we will research the case further. I am looking forward to your reply.

    All the best,
    Jack
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Stargazer
    Stargazer avatar
    73 posts
    Member since:
    Jan 2007

    Posted 25 Nov 2009 Link to this post

    Hi Jack.

    Gladly. :) My data is as follows (I'm putting a link to imageshack so you can see a picture of the final result):

    1. - There is a group of students;
    2. - They all have grades;
    3. - The grades are hierarchical, based on a tree of criteria;

    From top to bottom, as a simple example of one possible tree:

    Course
         Subject
             Subject Average
                 Year
                     1st Term
                     2nd Term
                         Test 1
                         Test 2
                         Test 3
                     3rd Term


    After some "heavy" processing, it's supposed to get something like this, on RadGridView

    |                              Course                                |
    |-----------------------------------------------------------|
    |                              Subject                                |
    |-----------------------------------------------------------|
    |                        Subject Average                        |
    |-----------------------------------------------------------|
    |                               Year                                   |
    |-------------|-------------------------------|--------------|
    | 1st Term |             2nd Term           |  3rd Term |
    |-------------|-------------------------------|--------------|
    |                |  Test 1 | Test 2 | Test 3  |                 |
    |-------------|----------|----------|----------|--------------|

    For a more visual and clear representation, go

    here


    P.S.: By the way, just a note... The link button on the toolbar here do not work in Firefox 3.5.5
  5. Answer
    Jack
    Admin
    Jack avatar
    2335 posts

    Posted 27 Nov 2009 Link to this post

    Hi Stargazer,

    Thank you for the detailed description. Now I understand what you want to achieve. As I said, currently you can create this kind of layout only with code. We will take this in account when planing our future versions. Also, thank you for the note about the button. I updated your Telerik points for the feedback. If you have any other questions, don't hesitate to ask.

    Kind regards,
    Jack
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Back to Top