Hi Mohan Kumar,
I had modified your code which works as you want..
Please check this code and let me know if further any problem.
public partial class
_Default : System.Web.UI.Page
{
protected void
Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
loadMyGrid();
}
}
public void
loadMyGrid()
{
string[] stuff = new string[]
{ "Mohan", "Arul Prakash", "Lakshman", "Ravindran", "Senthil", "Nagaraj", "Bala", "Suresh",
"Ashok" };
GridView1.DataSource
= stuff;
GridView1.DataBind();
}
protected void
GridView1_RowCreated(object sender,
GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.Header)
{
e.Row.Cells[0].Text
= "My Customized Grid Control";
}
}
}