이 경우 서버 측 콜백이 가능하면 OnRowDataBound- 이벤트를 만들고 특정 행을 찾아 레이블의 CSS 클래스를 다른 것으로 설정하십시오. 그 안에 Label이있는 TemplateColumn을 사용할 수 있습니다.
예.
protected void grid_RowDataBound(object sender, GridViewRowEventArgs e)
{
if(e.Row.RowType == RowType.DataRow)
{
YourObject _item = (YourObject)e.Row.DataItem;
Literal _litFromTemplate = (Literal)e.Row.FindControl("litFromTemplate");
if(_item.Equals(anotherItem)) // or check for any other condition, like _item.Foo == 123
{
_litFromTemplate.CssClass = 'highlightingMe';
}
else
{
_litFromTemplate.CssClass = 'normalcssclass';
}
}
}