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

Display Grid Columns Vertically

5 Answers 189 Views
This is a migrated thread and some comments may be shown as answers.
Marius
Top achievements
Rank 1
Marius asked on 11 Sep 2018, 07:43 AM

Is it possible to show the grid vertically as the example:

Name             Age      City
Marius           35       Kristiansand
Brian            37       Grimstad
Tom              38       Arendal

 

And show it as:

Name    Marius          Brian     Tom
Age     35              37        38
City    Kristiansand    Grimstad  Arendal

5 Answers, 1 is accepted

Sort by
0
Preslav
Telerik team
answered on 11 Sep 2018, 08:39 AM
Hi Marius,

To achieve the desired behavior, we have to transpose the data. An example is available in the following KB article:
Regards,
Preslav
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Marius
Top achievements
Rank 1
answered on 11 Sep 2018, 09:37 AM

Hello Preslav

I did try this, and here is a code example: https://stackblitz.com/edit/vertical-grid 
But the data from the new array is not shown.

0
Accepted
Preslav
Telerik team
answered on 11 Sep 2018, 12:00 PM
Hi Marius,

This problem comes from the fact that we are trying to bind the Grid columns to a number field. After changing the fields to "ProductName", and removing the spaces - the grid seems to work as expected on my side:

Regards,
Preslav
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Marius
Top achievements
Rank 1
answered on 11 Sep 2018, 12:16 PM

Thank you for the prompt reply.

Under mounted, the command:
this.$refs.grid.kendoWidget().dataSource.read(); 

Did the trick, and offcourse the removal of spaces.

Thank you so much.

0
Tấn Tâm
Top achievements
Rank 1
answered on 17 May 2019, 06:27 AM
asd
Asked by
Marius
Top achievements
Rank 1
Answers by
Preslav
Telerik team
Marius
Top achievements
Rank 1
Tấn Tâm
Top achievements
Rank 1
Share this question
or