DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world
Getting Access To Cell Contents Within Your GridView
Add OnRowDataBound = "RowDataBound" to your GridView control on your ASP.NET page
Add the below code to your code-behind page
public void RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.DataItemIndex > -1)
{
e.Row.Cells[0].Text = string.Format("{0,C}", e.Row.Cells[0].Text);
}
}





