Display Gridview's header in row instead of in column

Currently Gridview can display information in below format:
header1 header2 header3
row1      row2     row3
row4      row5     row6

Can i display the headers in the row like below?
header1  | col1  | col4
header2  | col 2 | col5
header3  | col3  | col6

If yes, how to do it?
Who is Participating?
tangteng78Connect With a Mentor Author Commented:
Finally found out the solution. By using DetailView, able to get the table format i want.
It seems that you need a pivot table. This example tells you how to create a pivot data table and bind it to a DataGrid. You should be able to use it for GridView as well.
tangteng78Author Commented:
It doesn't explain how it can be done using SqlDataSource web control? I'm using the sqldatasource to bind with GridView, thus user is able to edit, delete straight away in the GridView.
Any advice?
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.