I want to change the header text of the gridview using Design from <TemplateField HeaderText="">.
I created a variable in code behind which is public and set the value in that variable and then I tried to call that variable over here as below:
<TemplateField HeaderText = '<%= VariableCallHere %>'
But while running the page, I got <%= VariableCallHere %> as a header text.
Even I tried changing using gridView1.HeaderRow.Cells[0].Text = "text Here" (This Throws object reference error)
Any one have any suggestions how this could be achieved?