Recently, when you do a data list binding, you need the data column headings to dynamically change,
At first thought, through the HeaderText to find the corresponding column, and then set its headertext, found that it does not work;
Column.headertext= "TEST", I was written in the Bindgrid (), Can't you change the column at this time?
So, just try to create each row of rows of data?
In the Row_create () event, Judge E. Row.rowtype = = header, set E. row.cell[the corresponding column index]. text= "TEST" to write,
The operation can be set dynamically;
Later, also consulted the next colleague, they are generally written under the Row_databound,
The same code, pasted into the row_databound is also possible,
Then it appears that the Girdview data is generated in one line, and the content can be modified by a single line.
Mark has.
GridView Modify column Header HeaderText