I have added rows into gridview. There are 20 columns in gridview. How can i do a colspan-like feature in gridview which could show me 2-3 rows under 2-3 columns and remaining as a colspan.
Basically i wish to implement colspan in gridview on the rows of the gridview.
hence my present gv is like ;
Col 1 Col 2 Col 3 Col 4 …… Col 20
Cell1 Cell2 Cell3 Cell 4 …… Cell 20 (For Rows # 1)
I wish to have something like
Col 1 Col 2 Col 3 Col 4 …… Col 20
Cell1 Cell2 ...... Cell 20 (For Rows # 1)
Let me know for any query.
Thanks
You need to handle the OnRowCreated event of the GridView as follows:
Your markup should be something like this:
On the above example, I populated the grid with this:
And it produces this:

I just realized that you wanted to have the ROWS (not necessarily the header) to have certain colspan, in which case you can do:
And it will produce: