I wrote a jquery plugin. To achieve the effect of grouping.
Figure 2. This is a simple grouping effect, grouped by "Department" in the first column of the table
Figure 3, you can also group multiple columns, grouped by the first column "Department" and the fourth column "Gender". Before grouping, sort the columns you want to select, which can be done when you extract the data.
is not implemented on the client side.
Figure 4. You can set the parameter collapse=1. Let the table contract first. Its default value is 0;
By writing this jquery control, you are acutely aware of its power. The entire code is less than 100 lines.
Inside the asp.net. When the GridView is displayed by default, the tbody tag is not added. In order for the GridView class capacity to be displayed in Tbody, the following code can be added to page load
gridview1.useaccessibleheader=true;
GridView1.HeaderRow.TableSection = tablerowsection.tableheader; & nbsp;
GridView1.FooterRow.TableSection = Tablero Wsection.tablefooter;
So that you can use jquery.grouptable to handle the GridView-generated table.
Pack-and-download
Welcome your comments.