NewLIne 超过的字符 自动换行

//GridView控件行数据绑定事件
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow) //如果是数据行
{
//已设置公告内容列的宽度是200
//为公告内容列添加word-break属性
e.Row.Cells[2].Style.Add("word-break", "break-all");
}
}

posted @ 2013-01-19 17:10  yellowshorts  阅读(235)  评论(0编辑  收藏  举报