Movement, change DataGrid color Selection from Y97523SZB blog

xiaoxiao2021-03-06  51

Sub DataGrid1_ItemDataBound (ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DataGridItemEventArgs) If e.Item.ItemType = ListItemType.Item Or _ e.Item.ItemType = ListItemType.AlternatingItem Then '------ -------------------------------------------- 'add the onmouseover and OnMouseout Method to The Row Of DataGrid '------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ . backgroundColor = 'white' ") End If End Sub Sub DataGrid2_ItemDataBound (ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DataGridItemEventArgs) If e.Item.ItemType = ListItemType.Item Or _ e.Item.ItemType = ListitemType.alternatingItem Ten '--------------------------------------------- ------ 'Add The onmouseover and onmouseout Method a Cell (Colum n) of dataGrid '------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------ E.Item.cells (1) .attributes.add ("onmouseover", "this.style.BackgroundColor = '# DDEEFF'") E.Item.cells (1) .attributes.add (" OnMouseout "," this.style.backgroundcolor = 'white' ") '-------------------------------- ----------------- 'Change The Mouse Cursor of a Particular Cell (Column) of DataGrid' (or You May Do It for A Whole Row Of DataGrid :) '--- ---------------------------------- E. Item.cells (3) .style ("cursor") =

转载请注明原文地址:https://www.9cbs.com/read-115562.html

New Post(0)