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

Merged Columns (Dynamically) in RAD Grid

1 Answer 147 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Gajender Singh
Top achievements
Rank 1
Gajender Singh asked on 16 Dec 2008, 09:35 AM
I am looking for a solution through which I want to Merge columns dynamically and in variable count.

Same page with single grid will have the option of chosing the concerned project. Depending upon the project selected, the project related data will bind to the grid. Here the columns will vary from project to project as their duration will not similar. At the same time this merging is also required.

Project A 1

 

Activities

November, 2007

December, 2007

Planned

Actual

Planned

Actual

First Activity

3,000.00

2,500.00

5,000.00

7,200.00

Second Activity

1,500.00

2,000.00

600.00

1,000.00

 

Project A 12

Activities

January, 2008

February, 2008

March, 2008

Planned

Actual

Planned

Actual

Planned

Actual

First Activity

3,00.00

2,50.00

5,00.00

7,20.00

5,00.00

7,20.00

Second Activity

1,50.00

2,00.00

600.00

1,00.00

600.00

1,00.00

Third Activity

15.00

10.00

45.00

45.00

60.00

20.00

 

I am in confusion that How to achieve this with RAD Grid.....? 

 

Regards

1 Answer, 1 is accepted

Sort by
0
Sebastian
Telerik team
answered on 17 Dec 2008, 09:07 AM
Hi Gajender,

There are two possible solutions for your case:

  1. Create separate grids for each of your projects and change their visibility on-the-fly depending on the project you would like to display for the end users. In order to have multi-header layout, consider adding html tables to the header/item templates of a template column as illustrated in this help topic.
  2. Consider using auto-generated columns in your grid and span some of the header/item cells over multiple positions as demonstrated in the sample from the code library thread linked below:

    http://www.telerik.com/community/code-library/aspnet-ajax/grid/span-cells-in-grid-over-multiple-positions.aspx
Best regards,
Sebastian
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Grid
Asked by
Gajender Singh
Top achievements
Rank 1
Answers by
Sebastian
Telerik team
Share this question
or