悟生慧

 

DataGrid行随鼠标变色

private void DGzf_ItemDataBound(object sender, System.Web.UI.WebControls.DataGridItemEventArgs e) 

if (e.Item.ItemType!=ListItemType.Header) 

e.Item.Attributes.Add( "onmouseout","this.style.backgroundColor=\""+e.Item.Style["BACKGROUND-COLOR"]+"\""); 
e.Item.Attributes.Add( "onmouseover","this.style.backgroundColor=\""+ "#EFF3F7"+"\""); 

posted on 2010-07-14 16:42  悟生慧  阅读(187)  评论(0编辑  收藏  举报

导航