Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Praveen on Oct 22, 2009 12:25
open dhtmlx forum
Display Records as columns or Header Columns orientation on the left or right

I need to display all the Column headers on the left side of the table.
All the rows should appear as a column.

how can i do that. Please help?

--
Thanks
Answer posted by Alex (support) on Oct 23, 2009 02:54

Hello,

text align in the header cells depends on the chosen skin. But you can redefine it in the 3rd paramter of the setHeader method:

var headerStyle = ["text-align:left","text-align:left","text-align:left"];
grid.setHeader("Column1,Column2,Column3",",",headerStyle);

Answer posted by Stanislav (support) on Oct 23, 2009 02:55
Grid can't just rotate itself, but you can use per-cell typing and custom styles for the cells to achieve the necessary effect. 
http://www.dhtmlx.com/docs/products/dhtmlxGrid/samples/01_cell_types/05_pro_col_excell.html
Answer posted by Praveen on Oct 23, 2009 06:36
I am trying to get a record of 37 columns and display all the record values and column header.. Displaying them in a columns as displayed in this link http://www.dhtmlx.com/docs/products/dhtmlxGrid/samples/01_cell_types/05_pro_col_excell.html.    A column should contain a record from database(or data from the XML file)..

is there a way?
Answer posted by Stanislav (support) on Oct 23, 2009 07:48
The existing server side code can't be used for such task, so you will need to create a custom solution. 
Technically it possible to form necessary xml data on server side to show grid as you want.