/// <summary>
/// 數(shù)據(jù)綁定。。這個(gè)主要是解決數(shù)字類型出現(xiàn)錯(cuò)誤。
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
for (int i = 0; i < e.Row.Cells.Count; i++)
{
e.Row.Cells[i].Attributes.Add("style", "vnd.ms-excel.numberformat: @;");
}
}
}